You've already forked python-uncompyle6
mirror of
https://github.com/rocky/python-uncompyle6.git
synced 2025-08-03 00:45:53 +08:00
Warn about byte type when decompiling Python3 from Python2
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
# Copyright (C) 2018-2019 Rocky Bernstein <rocky@gnu.org>
|
||||
# Copyright (C) 2018-2020 Rocky Bernstein <rocky@gnu.org>
|
||||
#
|
||||
# This program is free software: you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
@@ -100,6 +100,9 @@ def decompile(
|
||||
"\n# ".join(sys_version_lines),
|
||||
)
|
||||
)
|
||||
if PYTHON_VERSION < 3.0 and bytecode_version >= 3.0:
|
||||
write("# Warning: this version has problems handling the Python 3 byte type in contants properly.\n")
|
||||
|
||||
if co.co_filename:
|
||||
write("# Embedded file name: %s" % co.co_filename,)
|
||||
if timestamp:
|
||||
|
Reference in New Issue
Block a user