Message266226
Nick, I've seen the come-up several times with people learning about context managers. The current error message seems cause confusion because it checks for __exit__ before __enter__, implying that the __enter__ is optional which it isn't. Do you have any objections testing for __enter__ first? |
|
Date |
User |
Action |
Args |
2016-05-24 05:28:48 | rhettinger | set | recipients:
+ rhettinger, ncoghlan, xiang.zhang, ellingtonjp |
2016-05-24 05:28:48 | rhettinger | set | messageid: <1464067728.69.0.334509726499.issue27100@psf.upfronthosting.co.za> |
2016-05-24 05:28:48 | rhettinger | link | issue27100 messages |
2016-05-24 05:28:48 | rhettinger | create | |
|