Comments (10)
I have hit the same issue (both the invalid type '\x19' and the UnsupportedCompressionMethodError issue.)
I don't have control over the process that's compressing these files. I'm hoping that someone has found a workaround for this.
from pylzma.
FYI: I tried @Marginal's code (https://github.com/Marginal/pylzma) and still have the issue when opening 7z files created by NetApp's ONTAP operating system (assuming @aaronsims-netapp has the same issue).
File "/usr/local/lib/python2.7/dist-packages/pylzma-0.4.8_14_gaea5dev-py2.7-linux-x86_64.egg/py7zlib.py", line 612, in read
raise UnsupportedCompressionMethodError(repr(coder['method']))
py7zlib.UnsupportedCompressionMethodError: '!'
EDIT: the invalid type issue seems to be gone, its just the UnsupportedCompressionMethodError remaining.
from pylzma.
Further info:
libmagic identifies the 7z file I'm having a problem with as:
body.7z: 7-zip archive data, version 0.4
version 0.3 and prior have no issue.
from pylzma.
In the ArchiveFile.read(), in the for loop for coder in self._folder.coders:
With both a version 0.3 7z file and a version 0.4 7z file, on first call of the read() function, the coder
pointer is:
{'numinstreams': 1, 'numoutstreams': 1, 'method': '\\x03\\x01\\x01', 'properties': ']\\x00`\\x00\\x00'}
On second call of the read() function:
-
version 0.3 is:
{'numinstreams': 1, 'numoutstreams': 1, 'method': '\\x03\\x01\\x01', 'properties': ']\\x00`\\x00\\x00'}
-
version 0.4 is:
"{'numinstreams': 1, 'numoutstreams': 1, 'method': '!', 'properties': '\\x04'}
This is what's throwing the error.
from pylzma.
Further information.
The file in question extracts without issue using 7-zip and p7zip version 9.20
from pylzma.
Could you please provide a small example file that can be used to reproduce the error?
from pylzma.
Yes, however it might contain confidential information so am I able to send outside of this thread?
from pylzma.
Sure, you should see my email address in my profile. However a small public file would be great, so I could add it as testcase if/when the problem is solved.
from pylzma.
I've sent you the confidential one. I'll try to get you one that can be public. Stay tuned.
from pylzma.
This file has the same issue (was created with Keka for Mac version 1.1.1 (2733).
Sorry it had to be zipped as GitHub doesn't allow uploading of 7z files.
from pylzma.
Related Issues (20)
- Bugs Report : Incorrect stream properties
- Data error during extraction HOT 20
- Feature request: read 7zip file line by line HOT 1
- py7zlib fails with `IndexError: list index out of range` when opening specific 7z archive HOT 13
- py7zlib fails when decompressing lzma2 bcj2 7z file HOT 2
- Feature: py7zlib: archive file mode and format API HOT 2
- Can't decompress the lzma1900.7z file using py7zlib.Archive7z HOT 1
- py7zlib: _read64Bit() returns None when reading bytes start with 0xff HOT 1
- Incorrect stream properties (TypeError) while trying to decompress HOT 1
- How read a 7z file with volumes?
- Do not automatically skip directory entries
- Feature: Add support for streaming ArchiveFiles HOT 2
- Hope to achieve the function of encryption
- Recent important updates not on pypi HOT 2
- Requested pylzma==0.5.0 but installing version is 0.5.0.post0 HOT 1
- index error
- python2 syntax in test_usage.py
- "pip instal pylzma" not working
- Building FreeBSD port archivers/py-lzma fails with error
- compliation fails on OpenBSD 7.3 / Python 3.10
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from pylzma.