tarfile.py question

John Hunter jdhunter at nitace.bsd.uchicago.edu
Fri Jul 26 11:30:05 EDT 2002


>>>>> "Adonis" == Adonis  <deltapigz at telocity.com> writes:

    Adonis> i attempted to read a tar.gz file (gadfly) and when i load
    Adonis> it no error is posted nor any information at that, but the
    Adonis> m variable is an empty list, and if i attempted to do
    Adonis> x.list() to get a list of files it returns None, although
    Adonis> it seems that it loaded the tar file properly no IOError
    Adonis> was generated, is there something i am missing? i have
    Adonis> tested this by generating a tar.gz file using the same
    Adonis> module and it unpacked properly.

Since it works for one tar file and not another, you may want to make
sure the gadfly tarfile is valid.  You can get a copy of GNU tar and
gzip for DOS to do this.  If you transferred the tar file via command
line ftp and forgot to type 'binary', it could be corrupt.

John Hunter




More information about the Python-list mailing list