Comment 9 for bug 44773

Revision history for this message
Christian Reis (kiko) wrote :

There seems to be some confusion regarding this bug, so I'll put my findings here.

1. Andrew is right that the bug in the default ordering of the dictionary affects us; the right way to fix this is to handle .gz, .tar and .bz2 files explicitly in the code, invoking the right classmethod directly, or supplying "r|xxx" to tarfile.open.

2. Python2.4's bzopen method doesn't support external file objects; they need to be files. However, if you supply them to open() they are meant to work, because they are then wrapped in a tarfile._Stream.

3. I can't seem to understand what went wrong in OOPS-135A37. It's strange: we tried to open it as a bzip2 file (note the "r|bz2" in the traceback), but the file inside the bz2 wrapper seems to have been empty. We shouldn't error out in this case, of course, but it seems that we do. But why was the file empty?