[issue24693] zipfile: change RuntimeError to more appropriate exception type

2016-09-10 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Changed cases 3, 4, 5, 7, and 8. -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker

[issue24693] zipfile: change RuntimeError to more appropriate exception type

2016-09-10 Thread Roundup Robot
Roundup Robot added the comment: New changeset 22112359abcf by Serhiy Storchaka in branch 'default': Issue #24693: Changed some RuntimeError's in the zipfile module to more https://hg.python.org/cpython/rev/22112359abcf -- nosy: +python-dev ___

[issue24693] zipfile: change RuntimeError to more appropriate exception type

2016-05-15 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Updated patch includes changed tests and the documentation. It includes changes for new exceptions added in issue26039. Perhaps not all changes should be accepted, but I have included them for demonstrating. RuntimeError was used in following cases: 1.

[issue24693] zipfile: change RuntimeError to more appropriate exception type

2016-05-14 Thread Martin Panter
Martin Panter added the comment: 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

[issue24693] zipfile: change RuntimeError to more appropriate exception type

2015-07-23 Thread Serhiy Storchaka
New submission from Serhiy Storchaka: RuntimeError is raised in the zipfile module in many cases where more appropriate exception type is expected. Proposed patch changes a number of RuntimeErrors to one of BadZipFile, NotImplementedError, or ValueError. Only changing to NotImplementedError