[Python-Dev] PEP 490: Chain exceptions at C level
Nick Coghlan
ncoghlan at gmail.com
Sat Jun 20 16:19:40 CEST 2015
More information about the Python-Dev mailing list
Sat Jun 20 16:19:40 CEST 2015
- Previous message (by thread): [Python-Dev] PEP 490: Chain exceptions at C level
- Next message (by thread): [Python-Dev] PEP 490: Chain exceptions at C level
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
On 20 June 2015 at 19:00, Stefan Behnel <stefan_ml at behnel.de> wrote: > And that is the crux in your proposal: you're changing the default > behaviour into its opposite. In order to do that, it should be reasonably > likely that the current standard behaviour is not intended in more than > half of the cases. I find that difficult to estimate. I think in this case the design decision can be made more on the basis of how difficult it is to flip the behaviour to the non-default case: Status quo: "Dear CPython core developers, why do you hate us so? Signed, everyone that has ever needed to manually chain exceptions at the C level using the current C API" (OK, it's not *that* bad as C level coding goes, but it's still pretty arcane, requiring a lot of knowledge of exception handling implementation details) With Victor's PEP: "Call PyErr_Clear() before setting your exception to disable the implicit exception chaining in 3.6+ in a way that remains entirely compatible with older Python versions" Given that significant difference in relative usability, +1 from me for changing the default behaviour. Cheers, Nick. -- Nick Coghlan | ncoghlan at gmail.com | Brisbane, Australia
- Previous message (by thread): [Python-Dev] PEP 490: Chain exceptions at C level
- Next message (by thread): [Python-Dev] PEP 490: Chain exceptions at C level
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the Python-Dev mailing list