[issue30017] zlib.error: Error -2 while flushing: inconsistent stream state

2017-04-16 Thread Serhiy Storchaka
Changes by Serhiy Storchaka : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker

[issue30017] zlib.error: Error -2 while flushing: inconsistent stream state

2017-04-16 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: New changeset 8e5b52a8da07e781bda50ba0a7065b1058495a37 by Serhiy Storchaka in branch '3.6': bpo-30017: Allowed calling the close() method of the zip entry writer object (#1041) (#1092)

[issue30017] zlib.error: Error -2 while flushing: inconsistent stream state

2017-04-12 Thread Serhiy Storchaka
Changes by Serhiy Storchaka : -- pull_requests: +1234 ___ Python tracker ___ ___

[issue30017] zlib.error: Error -2 while flushing: inconsistent stream state

2017-04-12 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: New changeset 4c0d9ea995da595e90e08813b89510de59907802 by Serhiy Storchaka in branch 'master': bpo-30017: Allowed calling the close() method of the zip entry writer object (#1041)

[issue30017] zlib.error: Error -2 while flushing: inconsistent stream state

2017-04-08 Thread Serhiy Storchaka
Changes by Serhiy Storchaka : -- pull_requests: +1194 ___ Python tracker ___ ___

[issue30017] zlib.error: Error -2 while flushing: inconsistent stream state

2017-04-08 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: I agree, that close() should be an idempotent operation. Proposed patch fixes this. -- assignee: -> serhiy.storchaka components: +Library (Lib) stage: needs patch -> patch review versions: +Python 3.7 ___ Python

[issue30017] zlib.error: Error -2 while flushing: inconsistent stream state

2017-04-07 Thread Martin Panter
Martin Panter added the comment: It looks like the zip entry writer object may not expect its “close” method to be called multiple times. Other file objects tend to allow this with no ill effect. Adding Serhiy and Thomas who implemented the writer object in Issue 26039. The first time it is

[issue30017] zlib.error: Error -2 while flushing: inconsistent stream state

2017-04-07 Thread Ellison Marks
Ellison Marks added the comment: At a guess, when encoder goes out of scope, it closes the underlying file object. Then, on exiting the with block, the zipfile tries to take some action with the closed file and errors out? -- nosy: +Ellison Marks

[issue30017] zlib.error: Error -2 while flushing: inconsistent stream state

2017-04-07 Thread Xiang Zhang
Changes by Xiang Zhang : -- nosy: +xiang.zhang ___ Python tracker ___ ___ Python-bugs-list

[issue30017] zlib.error: Error -2 while flushing: inconsistent stream state

2017-04-07 Thread Jeremy Heiner
Changes by Jeremy Heiner : -- title: zlib -> zlib.error: Error -2 while flushing: inconsistent stream state ___ Python tracker