Message274864
> No, the suggestion is to only adopt the first part of the patch from 2010, which is to revert KeyError to behave like LookupError again
That ship has sailed long ago. 2.7, 3.4 and 3.5 (the three major Python versions currently in use) all have the same behaviour, and nobody seems to complain very loudly:
>>> {}['foo']
Traceback (most recent call last):
File "<ipython-input-2-3761c7dc3711>", line 1, in <module>
{}['foo']
KeyError: 'foo'
>>> KeyError('foo')
KeyError('foo')
>>> print(KeyError('foo'))
'foo' |
|
Date |
User |
Action |
Args |
2016-09-07 18:40:53 | pitrou | set | recipients:
+ pitrou, rhettinger, amaury.forgeotdarc, belopolsky, rharris, eric.araujo, vencabot_teppoo, lukasz.langa, Julian, martin.panter |
2016-09-07 18:40:53 | pitrou | set | messageid: <1473273653.64.0.768221051516.issue2651@psf.upfronthosting.co.za> |
2016-09-07 18:40:53 | pitrou | link | issue2651 messages |
2016-09-07 18:40:53 | pitrou | create | |
|