Le 14/09/11 11:31, Arnaud Delobelle a écrit :
[vincent@myhost unpyc3]$ pythonOn 14 September 2011 09:44, Vincent Vande Vyvre <vincent.vandevy...@swing.be> wrote:File "unpyc3.py", line 211, in __init__ for v in code_obj.co_cellvars + code_obj.co_freevars] AttributeError: 'NoneType' object has no attribute 'co_cellvars'Could you show me what you do to get this error? Thank you,Arnaud PS: I've checked; DELETE_DEREF was introduced in Python3.2 Python 3.2.1 (default, Jul 11 2011, 12:37:47) [GCC 4.6.1] on linux2 Type "help", "copyright", "credits" or "license" for more information. >>> from unpyc3 import decompile >>> print (decompile("shredder.pyc")) Traceback (most recent call last): File "<stdin>", line 1, in <module> File "unpyc3.py", line 110, in decompile return dec_module(obj) File "unpyc3.py", line 99, in dec_module code = Code(code_obj) File "unpyc3.py", line 211, in __init__ for v in code_obj.co_cellvars + code_obj.co_freevars] AttributeError: 'NoneType' object has no attribute 'co_cellvars' >>> print (decompile("unpyc3.pyc")) Traceback (most recent call last): File "<stdin>", line 1, in <module> File "unpyc3.py", line 110, in decompile return dec_module(obj) File "unpyc3.py", line 99, in dec_module code = Code(code_obj) File "unpyc3.py", line 211, in __init__ for v in code_obj.co_cellvars + code_obj.co_freevars] AttributeError: 'NoneType' object has no attribute 'co_cellvars' >>> import os >>> os.path.isfile("shredder.pyc") True >>> os.path.isfile("unpyc3.pyc") True >>> it seems the return of marshal.load(stream) is None |
-- http://mail.python.org/mailman/listinfo/python-list