Author Anthony Sottile
Recipients Anthony Sottile, Deep Sukhwani, eric.araujo, flox, jwillikers, kfunk, lars.gustaebel, vstinner
Date 2021-03-16.00:05:55
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <>
I took a stab at improving the error message (see the linked PR)

$ ./python -c 'import tarfile;"Lib/test/testtar.tar.xz")'
Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "/home/asottile/workspace/cpython/Lib/", line 1620, in open
    raise ReadError(f"file could not be opened successfully:\n{error_msgs}")
tarfile.ReadError: file could not be opened successfully:
- method gz: ReadError('not a gzip file')
- method bz2: CompressionError('bz2 module is not available')
- method xz: CompressionError('lzma module is not available')
- method tar: ReadError('truncated header')
Date User Action Args
2021-03-16 00:05:55Anthony Sottilesetrecipients: + Anthony Sottile, lars.gustaebel, vstinner, eric.araujo, flox, kfunk, Deep Sukhwani, jwillikers
2021-03-16 00:05:55Anthony Sottilesetmessageid: <>
2021-03-16 00:05:55Anthony Sottilelinkissue8978 messages
2021-03-16 00:05:55Anthony Sottilecreate