[issue6524] tarfile module missing decompression support?

2009-07-19 Thread Henrik ravn

New submission from Henrik ravn :

When doing the following with python 2.6.2 on Windows Vista SP1:

>>> import tarfile
>>> tf = tarfile.TarFile("sometarfile.tar.bz2")

Traceback (most recent call last):
  File "", line 1, in 
tf = tarfile.TarFile("sometarfile.tar.bz2")
  File "C:\Python26\lib\tarfile.py", line 1570, in __init__
self.firstmember = self.next()
  File "C:\Python26\lib\tarfile.py", line 2322, in next
raise ReadError(str(e))
ReadError: invalid header

This would, of course, suggest that the file was corrupted, but all 
archiving tools (tar, winrar and 7-zip) handle the file without 
problems. 

Also:

>>> tf = tarfile.TarFile("sometarfile.tar.bz2", "r:bz2")

Traceback (most recent call last):
  File "", line 1, in 
tf = tarfile.TarFile("e:/mono/mono-2.4.2.2.tar.bz2", "r:bz2")
  File "C:\Python26\lib\tarfile.py", line 1510, in __init__
raise ValueError("mode must be 'r', 'a' or 'w'")
ValueError: mode must be 'r', 'a' or 'w'

which suggests that the compression support is not compiled into the 
tarfile module.

--
components: Library (Lib)
messages: 90724
nosy: hravnx
severity: normal
status: open
title: tarfile module missing decompression support?
type: behavior
versions: Python 2.6

___
Python tracker 
<http://bugs.python.org/issue6524>
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue6524] tarfile module missing decompression support?

2009-07-20 Thread Henrik ravn

Henrik ravn  added the comment:

Nevermind - apparently I misunderstood the docs. Sorry.

--
status: open -> closed

___
Python tracker 
<http://bugs.python.org/issue6524>
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com