This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author johnsonm
Recipients johnsonm
Date 2009-06-10.15:46:50
SpamBayes Score 6.1702865e-12
Marked as misclassified No
Message-id <1244648812.36.0.982521816376.issue6254@psf.upfronthosting.co.za>
In-reply-to
Content
In python 2.6 (not 2.4, haven't checked 2.5), the __init__() method of
the TarFile class calls the tell() method on the tar file, which doesn't
work if you are reading from standard input or writing to standard
output, two very reasonable things to do with a tar file.

While there are cases where it is logical to seek within a tar file,
supporting those cases should not preclude the normal design case for
tar archives of streaming reads/writes, including tar files being
streamed between processes via pipes.  If the tell() method is not
implemented for the file object, then the seek() method of TarFile (and
any other methods that can be implemented only for seekable files) can
raise a reasonable exception.  Note that this also means that the next()
method should not need to seek() for non-seekable files; it should
assume that it is at the correct block and read from there.
History
Date User Action Args
2009-06-10 15:46:52johnsonmsetrecipients: + johnsonm
2009-06-10 15:46:52johnsonmsetmessageid: <1244648812.36.0.982521816376.issue6254@psf.upfronthosting.co.za>
2009-06-10 15:46:51johnsonmlinkissue6254 messages
2009-06-10 15:46:50johnsonmcreate