[New-bugs-announce] [issue20262] Convert some debugging prints in zipfile to warnings

Serhiy Storchaka report at bugs.python.org
Tue Jan 14 21:56:35 CET 2014


New submission from Serhiy Storchaka:

When ZipFile.debug is not zero, some debugging messages are printed to stdout. Some of them are for debugging the zipfile module itself. But some are warnings about user's operation which perhaps make not what the user is expected -- truncating long archive comment or adding a file with duplicated name. These cases cases can be considered as logic error, they can be prevented by external checks (check that comment's length does not excite the limit and that specified name is not in the ZIP file). So it will be sane and helpful to convert these prints to regular warnings, which are controlled in same way as all other warnings.

See also issue2824. It have a patch which looks too excessive to me.

Here is a patch. I don't sure to which version it should be targeted.

----------
components: Library (Lib)
files: zipfile_warnings.patch
keywords: patch
messages: 208112
nosy: alanmcintyre, georg.brandl, larry, serhiy.storchaka
priority: normal
severity: normal
stage: patch review
status: open
title: Convert some debugging prints in zipfile to warnings
Added file: http://bugs.python.org/file33468/zipfile_warnings.patch

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue20262>
_______________________________________


More information about the New-bugs-announce mailing list