Message265558
I have hardly used the zipfile module, but here are my thoughts on some of the exceptions anyway :)
Some of these exceptions are documented, so the documentation would need updating.
BadZipFile for corrupted field seems reasonable.
The purpose of RuntimeError is not clearly documented, but I have the feeling it gets used mainly for programmer errors, rather than errors caused by external data. So I tend to agree a couple of the changes away from RuntimeError, such as the invalid password case.
For programmer errors, I doubt the exception type matters much for compatibility. RuntimeError seems fine to me, but I accept that ValueError is more consistent with open(..., mode="invalid"), operations on closed files, etc. |
|
Date |
User |
Action |
Args |
2016-05-14 23:18:23 | martin.panter | set | recipients:
+ martin.panter, twouters, ronaldoussoren, alanmcintyre, ned.deily, serhiy.storchaka |
2016-05-14 23:18:23 | martin.panter | set | messageid: <1463267903.7.0.178052869231.issue24693@psf.upfronthosting.co.za> |
2016-05-14 23:18:23 | martin.panter | link | issue24693 messages |
2016-05-14 23:18:23 | martin.panter | create | |
|