-
Notifications
You must be signed in to change notification settings - Fork 310
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Unable to decompile any .pyc file #23
Comments
Hi, |
Hi, After adding the magic number in magics.py file, now its giving me "ValueError: bad marshal data (unknown type code)" Is this error specific to uncompyle2 or python? For different files there are different errors, can you please give me any specific file that can be compiled back to .py Thanks, |
That error comes from the marshal module which is a standard python module. The marshal module is used by python to serialize python objects, particularly code objects. Uncompyle2 uses the marshal module to unserialize the code in a pyc file into a live python code object. Usually the marshal format doesn't change much between versions of python, but that error indicates that the version of python which generated your .pyc files has changed the marshal format enough to no longer be compatible with the version of python which is executing uncompyle2. You can see the marshal type codes of the latest python 2.7 release here: http://svn.python.org/projects/python/branches/release27-maint/Python/marshal.c |
Hi wibiti, Thanks for the information you are providing, according to your last reply does it mean files I am trying are not compatible with uncompyle2. And does 2.7 means 2.7.x (x = 3 or any version number) compiled file will not work with 2.7 uncompyle2? Thanks, |
uncompyle2 should work with 2.7.1 through 2.7.3. I'm not sure about 2.7.0 I'm not sure what version of python generated your .pyc files, but from the There is a chance that if you have the version of python that compiled On Thu, Feb 21, 2013 at 7:10 AM, Vimarsh N Sharma
|
Hi wibiti, I want to get some files decompiled, if you feel fine can you please send me your details to my email address sharmavimarsh@gmail.com so I can send you files as files are important for me. Thanks, |
Hi Vimarsh, I don't have a lot of time available for this kind of work. I'm sorry uncompyle2 isn't able to decompile your files. |
Hi wibiti, Thanks for co-operation, I will go through the link you have suggested and meanwhile I will ask if I came through any error or help. Thanks, |
I am also facing the same issue. After adding the magic number (62215) I am getting this error, ValueError: bad marshal data (unknown type code). I also tried this one https://github.com/Mysterie/uncompyle2 but still same issues. Vimarsh, Can you able to decompile after that ? I would appreciate if someone can guide me to retrieve files from that. Please let me know if you need any sample file having the problem. Thanks, |
suggested by former maintainer wibiti/uncompyle2#23 (comment)
Hi,
I am using Uncompyle2 for my own purpose and trying to decompile .pyc file to py with 2.7 Python Shell for this.
Below is the message I am getting :
Traceback (most recent call last):
File "<pyshell#11>", line 1, in
uncompyle2.uncompyle_file("\Queue.pyc",None,0,0)
File "C:\uncompyle2\uncompyle2__init__.py", line 140, in uncompyle_file
version, co = load_module(filename)
File "C:\uncompyle2\uncompyle2__init_.py", line 74, in _load_module
raise ImportError, "Unknown magic number %s in %s" % (ord(magic[0])+256*ord(magic[1]), filename)
ImportError: Unknown magic number 62215 in \Queue.pyc
Thanks,
Vimarsh
The text was updated successfully, but these errors were encountered: