You've already forked python-uncompyle6
mirror of
https://github.com/rocky/python-uncompyle6.git
synced 2025-08-03 00:45:53 +08:00
Better bytecode detection for Python > 3.0...
Not perfect though. More work is needed on the xdis side.
This commit is contained in:
@@ -80,6 +80,9 @@ for vers in TEST_VERSIONS:
|
|||||||
else:
|
else:
|
||||||
if vers == "native":
|
if vers == "native":
|
||||||
short_vers = os.path.basename(sys.path[-1])
|
short_vers = os.path.basename(sys.path[-1])
|
||||||
|
from xdis import PYTHON_VERSION
|
||||||
|
if PYTHON_VERSION > 3.0:
|
||||||
|
PYC = "*.cpython-%d.pyc" % int(PYTHON_VERSION * 10)
|
||||||
test_options[vers] = (sys.path[-1], PYC, short_vers)
|
test_options[vers] = (sys.path[-1], PYC, short_vers)
|
||||||
else:
|
else:
|
||||||
short_vers = vers[:3]
|
short_vers = vers[:3]
|
||||||
|
Reference in New Issue
Block a user