[issue13781] gzip module does the wrong thing with an os.fdopen()'ed fileobj

2014-04-05 Thread Ezio Melotti
Changes by Ezio Melotti : Removed file: http://bugs.python.org/file34740/test_tarfile_fdopen.diff ___ Python tracker ___ ___ Python-bugs-list

[issue13781] gzip module does the wrong thing with an os.fdopen()'ed fileobj

2014-04-05 Thread Ezio Melotti
Changes by Ezio Melotti : -- Removed message: http://bugs.python.org/msg215627 ___ Python tracker ___ ___ Python-bugs-list mailing lis

[issue13781] gzip module does the wrong thing with an os.fdopen()'ed fileobj

2014-04-05 Thread Antoine Pietri
Antoine Pietri added the comment: Actually, thinking about it, it seems safer to use os.open() + os.fdopen() than TemporaryFile(), like in the equivalent test for 'gzip'. This new patch replaces last one. -- nosy: +seirl Added file: http://bugs.python.org/file34740/test_tarfile_fdopen.

[issue13781] gzip module does the wrong thing with an os.fdopen()'ed fileobj

2012-01-18 Thread Nadeem Vawda
Nadeem Vawda added the comment: Done. -- resolution: -> fixed stage: -> committed/rejected status: open -> closed type: -> behavior ___ Python tracker ___ ___

[issue13781] gzip module does the wrong thing with an os.fdopen()'ed fileobj

2012-01-18 Thread Roundup Robot
Roundup Robot added the comment: New changeset a08e9e84f33f by Nadeem Vawda in branch '2.7': Issue #13781: Fix GzipFile to work with os.fdopen()'d file objects. http://hg.python.org/cpython/rev/a08e9e84f33f -- ___ Python tracker

[issue13781] gzip module does the wrong thing with an os.fdopen()'ed fileobj

2012-01-18 Thread Gregory P. Smith
Gregory P. Smith added the comment: Looks like you've got commit privs (yay) so i'm assigning this to you to take care of that way for 2.7 as well. I'd add a comment to the fdopen C code where the "" constant lives as well as to the gzip.py module around the special case for this mentioning t

[issue13781] gzip module does the wrong thing with an os.fdopen()'ed fileobj

2012-01-17 Thread Nadeem Vawda
Nadeem Vawda added the comment: > As far as fixing this for 2.7 goes, i don't like the _sound_ of it > because it is gross... But i'm actually okay with having special case > code in the gzip module that rejects '' as an actual filename > and uses '' instead in that case. It is VERY unlikely th

[issue13781] gzip module does the wrong thing with an os.fdopen()'ed fileobj

2012-01-17 Thread Roundup Robot
Roundup Robot added the comment: New changeset 7d405058e458 by Nadeem Vawda in branch '3.2': Issue #13781: Fix GzipFile to work with os.fdopen()'d file objects. http://hg.python.org/cpython/rev/7d405058e458 New changeset fe36edf3a341 by Nadeem Vawda in branch 'default': Merge: #13781: Fix GzipF

[issue13781] gzip module does the wrong thing with an os.fdopen()'ed fileobj

2012-01-17 Thread Gregory P. Smith
Gregory P. Smith added the comment: thanks that looks good. As far as fixing this for 2.7 goes, i don't like the _sound_ of it because it is gross... But i'm actually okay with having special case code in the gzip module that rejects '' as an actual filename and uses '' instead in that case.

[issue13781] gzip module does the wrong thing with an os.fdopen()'ed fileobj

2012-01-17 Thread Nadeem Vawda
Nadeem Vawda added the comment: Attached is a fix for 3.x. -- keywords: +patch Added file: http://bugs.python.org/file24258/gzip-fdopen.diff ___ Python tracker ___ _

[issue13781] gzip module does the wrong thing with an os.fdopen()'ed fileobj

2012-01-16 Thread Nadeem Vawda
Nadeem Vawda added the comment: For 3.x, I think that ignoring non-string names is a reasonable fix. The docs for io.FileIO specify that its name attribute can be either a path or an integer file descriptor, and changing this doesn't seem to serve any purpose. As for the case of 2.7's bogus ""

[issue13781] gzip module does the wrong thing with an os.fdopen()'ed fileobj

2012-01-15 Thread Jed Davis
Changes by Jed Davis : -- nosy: +jld ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mai

[issue13781] gzip module does the wrong thing with an os.fdopen()'ed fileobj

2012-01-13 Thread Antoine Pitrou
Changes by Antoine Pitrou : -- nosy: +nadeem.vawda versions: -Python 2.6, Python 3.1 ___ Python tracker ___ ___ Python-bugs-list mail

[issue13781] gzip module does the wrong thing with an os.fdopen()'ed fileobj

2012-01-13 Thread Gregory P. Smith
New submission from Gregory P. Smith : gzip.GzipFile accepts a fileobj parameter with an open file object. Unfortunately gzip requires a filename be embedded in the gzip file and the gzip module code uses fileobj.name to get that. This results in the fake "" name from posixmodule.c being embed