Hello community,

here is the log from the commit of package python-xdis for openSUSE:Factory 
checked in at 2019-12-04 13:53:23
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python-xdis (Old)
 and      /work/SRC/openSUSE:Factory/.python-xdis.new.4691 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "python-xdis"

Wed Dec  4 13:53:23 2019 rev:5 rq:753274 version:4.1.3

Changes:
--------
--- /work/SRC/openSUSE:Factory/python-xdis/python-xdis.changes  2019-10-31 
18:18:29.770211811 +0100
+++ /work/SRC/openSUSE:Factory/.python-xdis.new.4691/python-xdis.changes        
2019-12-04 14:20:11.210428362 +0100
@@ -1,0 +2,14 @@
+Tue Dec  3 14:27:40 UTC 2019 - Tomáš Chvátal <tchva...@suse.com>
+
+- Update to 4.1.3:
+  * Various dependency fixes
+
+-------------------------------------------------------------------
+Wed Nov  6 12:12:41 UTC 2019 - Tomáš Chvátal <tchva...@suse.com>
+
+- Update to 4.1.2:
+  * Python 3.8.0 magic changed
+  * More Pypy 3.6 tolerance
+  * Fixed DeprecationWarning; thanks to laike9m
+
+-------------------------------------------------------------------

Old:
----
  4.1.1.tar.gz

New:
----
  4.1.3.tar.gz

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ python-xdis.spec ++++++
--- /var/tmp/diff_new_pack.zAYVZh/_old  2019-12-04 14:20:12.670429593 +0100
+++ /var/tmp/diff_new_pack.zAYVZh/_new  2019-12-04 14:20:12.674429596 +0100
@@ -1,7 +1,7 @@
 #
 # spec file for package python-xdis
 #
-# Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany.
+# Copyright (c) 2019 SUSE LLC
 #
 # All modifications and additions to the file contributed by third parties
 # remain the property of their copyright owners, unless otherwise agreed
@@ -18,7 +18,7 @@
 
 %{?!python_module:%define python_module() python-%{**} python3-%{**}}
 Name:           python-xdis
-Version:        4.1.1
+Version:        4.1.3
 Release:        0
 Summary:        Python cross-version byte-code disassembler and marshal 
routines
 License:        GPL-2.0-only

++++++ 4.1.1.tar.gz -> 4.1.3.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/python-xdis-4.1.1/.travis.yml 
new/python-xdis-4.1.3/.travis.yml
--- old/python-xdis-4.1.1/.travis.yml   2019-10-29 13:21:01.000000000 +0100
+++ new/python-xdis-4.1.3/.travis.yml   2019-11-18 01:32:26.000000000 +0100
@@ -12,6 +12,7 @@
   - '3.5'
   - '3.6'
   - '3.7'
+  - '3.8'
   - 'pypy3'
 
 install:
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/python-xdis-4.1.1/NEWS.md 
new/python-xdis-4.1.3/NEWS.md
--- old/python-xdis-4.1.1/NEWS.md       2019-10-29 13:21:01.000000000 +0100
+++ new/python-xdis-4.1.3/NEWS.md       2019-11-18 01:32:26.000000000 +0100
@@ -1,3 +1,17 @@
+4.1.3 2019-10-29 JNC
+====================
+
+- Add magics for 3.5.8 and 3.5.9
+- Python 3.0 tolerance
+- Fix for unmarshaling Python 3.8 str from 3.2
+- Pypy 3.3, 3.5 3.6 and 3.6.9 magic numbers and support
+
+4.1.2 2019-10-29 pre Halloween redux
+====================================
+- Python 3.8.0 magic changed
+- More Pypy 3.6 tolerance
+- Fixed DeprecationWarning; thanks to laike9m
+
 4.1.1 2019-10-29 pre Halloween
 ==============================
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/python-xdis-4.1.1/README.rst 
new/python-xdis-4.1.3/README.rst
--- old/python-xdis-4.1.1/README.rst    2019-10-29 13:21:01.000000000 +0100
+++ new/python-xdis-4.1.3/README.rst    2019-11-18 01:32:26.000000000 +0100
@@ -5,7 +5,7 @@
 xdis
 ====
 
-Cross-Python bytecode Disassembler, Bytecode, and Magic Number Manipulation 
package
+A Cross-Python bytecode isassembler, bytecode/workcode and magic-number 
manipulation library/package.
 
 
 Introduction
@@ -52,8 +52,8 @@
 
 ::
 
-    pip install -e .
-    pip install -r requirements-dev.txt
+    $ pip install -e .
+    $ pip install -r requirements-dev.txt
 
 A GNU makefile is also provided so :code:`make install` (possibly as root or
 sudo) will do the steps above.
@@ -63,7 +63,7 @@
 
 ::
 
-   make check
+   $ make check
 
 A GNU makefile has been added to smooth over setting running the right
 command, and running tests from fastest to slowest.
@@ -79,7 +79,7 @@
 
 ::
 
-     ./bin/pydisasm -h
+     $ ./bin/pydisasm -h
 
 for usage help.
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/python-xdis-4.1.1/admin-tools/how-to-make-a-release.md 
new/python-xdis-4.1.3/admin-tools/how-to-make-a-release.md
--- old/python-xdis-4.1.1/admin-tools/how-to-make-a-release.md  2019-10-29 
13:21:01.000000000 +0100
+++ new/python-xdis-4.1.3/admin-tools/how-to-make-a-release.md  2019-11-18 
01:32:26.000000000 +0100
@@ -58,15 +58,16 @@
 
     $ bash && echo $SHLVL # Go into a subshell to protect exit
     $ source admin-tools/check-older-versions.sh
-    $ source admin-tools/check-newer-versions.sh
     $ echo $SHLVL ; exit
 
 # Make packages and tag
 
     $ . ./admin-tools/make-dist-older.sh
+       $ pyenv local 3.8.0
+       $ twine check dist/xdis-$VERSION*
     $ git tag release-python-2.4-$VERSION
-
     $ . ./admin-tools/make-dist-newer.sh
+       $ twine check dist/xdis-$VERSION*
 
 Goto https://github.com/rocky/python-xdis/releases
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/python-xdis-4.1.1/admin-tools/pyenv-newer-versions 
new/python-xdis-4.1.3/admin-tools/pyenv-newer-versions
--- old/python-xdis-4.1.1/admin-tools/pyenv-newer-versions      2019-10-29 
13:21:01.000000000 +0100
+++ new/python-xdis-4.1.3/admin-tools/pyenv-newer-versions      2019-11-18 
01:32:26.000000000 +0100
@@ -5,4 +5,4 @@
     echo "This script should be *sourced* rather than run directly through 
bash"
     exit 1
 fi
-export PYVERSIONS='3.6.9 3.7.5 2.6.9 3.3.7 2.7.16 3.4.10 3.5.7'
+export PYVERSIONS='3.5.9 3.6.9 2.6.9 3.3.7 2.7.17 3.2.6 3.1.5 3.4.10 3.7.5 
3.8.0'
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/python-xdis-4.1.1/admin-tools/setup-master.sh 
new/python-xdis-4.1.3/admin-tools/setup-master.sh
--- old/python-xdis-4.1.1/admin-tools/setup-master.sh   2019-10-29 
13:21:01.000000000 +0100
+++ new/python-xdis-4.1.3/admin-tools/setup-master.sh   2019-11-18 
01:32:26.000000000 +0100
@@ -1,5 +1,5 @@
 #!/bin/bash
-PYTHON_VERSION=2.7.16
+PYTHON_VERSION=3.7.5
 
 if [[ $0 == $${BASH_SOURCE[0]} ]] ; then
     echo "This script should be *sourced* rather than run directly through 
bash"
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/python-xdis-4.1.1/pytest/test_disasm.py 
new/python-xdis-4.1.3/pytest/test_disasm.py
--- old/python-xdis-4.1.1/pytest/test_disasm.py 2019-10-29 13:21:01.000000000 
+0100
+++ new/python-xdis-4.1.3/pytest/test_disasm.py 2019-11-18 01:32:26.000000000 
+0100
@@ -3,7 +3,7 @@
 import re
 
 from xdis.main import disassemble_file
-from xdis import PYTHON3
+from xdis import PYTHON3, PYTHON_VERSION
 
 if PYTHON3:
     from io import StringIO
@@ -20,52 +20,53 @@
     return os.path.realpath(filename)
 
 
-@pytest.mark.parametrize(
-    ("test_tuple", "function_to_test"),
-    [
-        (
-            ("../test/bytecode_3.6/01_fstring.pyc", 
"testdata/fstring-3.6.right"),
-            disassemble_file,
-        ),
-        (
-            ("../test/bytecode_3.0/04_raise.pyc", "testdata/raise-3.0.right"),
-            disassemble_file,
-        ),
-        (
+if PYTHON_VERSION >= 3.2:
+    @pytest.mark.parametrize(
+        ("test_tuple", "function_to_test"),
+        [
             (
-                "../test/bytecode_2.7pypy/04_pypy_lambda.pyc",
-                "testdata/pypy_lambda.right",
+                ("../test/bytecode_3.6/01_fstring.pyc", 
"testdata/fstring-3.6.right"),
+                disassemble_file,
             ),
-            disassemble_file,
-        ),
-        (
-            ("../test/bytecode_3.6/03_big_dict.pyc", 
"testdata/big_dict-3.6.right"),
-            disassemble_file,
-        ),
-        (("../test/bytecode_2.7/01_hexstring.pyc", hextring_file), 
disassemble_file),
-    ],
-)
-def test_funcoutput(capfd, test_tuple, function_to_test):
-    in_file, filename_expected = [os.path.join(get_srcdir(), p) for p in 
test_tuple]
-    resout = StringIO()
-    function_to_test(in_file, resout)
-    expected = "".join(open(filename_expected, "r").readlines())
-    got_lines = resout.getvalue().split("\n")
-    got_lines = [
-        re.sub(" at 0x[0-9a-f]+", " at 0xdeadbeef0000", line) for line in 
got_lines
-    ]
-    got_lines = [
-        re.sub(
-            "<code object .*>|<xdis.code.Code[23] (object|instance) .*>",
-            "<xdis.code.thingy instance at 0xdeadbeef0000>",
-            line,
-        )
-        for line in got_lines
-    ]
-    got = "\n".join(got_lines[5:])
-
-    if "XDIS_DONT_WRITE_DOT_GOT_FILES" not in os.environ:
-        if got != expected:
-            with open(filename_expected + ".got", "w") as out:
-                out.write(got)
-    assert got == expected
+            (
+                ("../test/bytecode_3.0/04_raise.pyc", 
"testdata/raise-3.0.right"),
+                disassemble_file,
+            ),
+            (
+                (
+                    "../test/bytecode_2.7pypy/04_pypy_lambda.pyc",
+                    "testdata/pypy_lambda.right",
+                ),
+                disassemble_file,
+            ),
+            (
+                ("../test/bytecode_3.6/03_big_dict.pyc", 
"testdata/big_dict-3.6.right"),
+                disassemble_file,
+            ),
+            (("../test/bytecode_2.7/01_hexstring.pyc", hextring_file), 
disassemble_file),
+        ],
+    )
+    def test_funcoutput(capfd, test_tuple, function_to_test):
+        in_file, filename_expected = [os.path.join(get_srcdir(), p) for p in 
test_tuple]
+        resout = StringIO()
+        function_to_test(in_file, resout)
+        expected = "".join(open(filename_expected, "r").readlines())
+        got_lines = resout.getvalue().split("\n")
+        got_lines = [
+            re.sub(" at 0x[0-9a-f]+", " at 0xdeadbeef0000", line) for line in 
got_lines
+        ]
+        got_lines = [
+            re.sub(
+                "<code object .*>|<xdis.code.Code[23] (object|instance) .*>",
+                "<xdis.code.thingy instance at 0xdeadbeef0000>",
+                line,
+            )
+            for line in got_lines
+        ]
+        got = "\n".join(got_lines[5:])
+
+        if "XDIS_DONT_WRITE_DOT_GOT_FILES" not in os.environ:
+            if got != expected:
+                with open(filename_expected + ".got", "w") as out:
+                    out.write(got)
+        assert got == expected
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/python-xdis-4.1.1/pytest/test_load_file.py 
new/python-xdis-4.1.3/pytest/test_load_file.py
--- old/python-xdis-4.1.1/pytest/test_load_file.py      2019-10-29 
13:21:01.000000000 +0100
+++ new/python-xdis-4.1.3/pytest/test_load_file.py      2019-11-18 
01:32:26.000000000 +0100
@@ -1,21 +1,20 @@
 import os, sys, pytest
-from xdis import IS_PYPY
+from xdis import IS_PYPY, PYTHON_VERSION
 from xdis.load import load_file, check_object_path, load_module
 
-@pytest.mark.skipif(sys.version_info >= (3,5),
-                    reason="Doesn't work on 3.5 and later")
-def test_load_file():
-    co = load_file(__file__)
-    obj_path = check_object_path(__file__)
-    (version, timestamp, magic_int, co2, pypy,
-     source_size) = load_module(obj_path)
-    if (3,3) <= sys.version_info:
-        statinfo = os.stat(__file__)
-        assert statinfo.st_size == source_size
-    else:
-        assert source_size is None
+if 3.3 < PYTHON_VERSION < 3.5:
+    def test_load_file():
+        co = load_file(__file__)
+        obj_path = check_object_path(__file__)
+        (version, timestamp, magic_int, co2, pypy,
+         source_size) = load_module(obj_path)
+        if (3,3) <= sys.version_info:
+            statinfo = os.stat(__file__)
+            assert statinfo.st_size == source_size
+        else:
+            assert source_size is None
 
-    if IS_PYPY:
-        assert str(co) == str(co2)
-    else:
-        assert co == co2
+        if IS_PYPY:
+            assert str(co) == str(co2)
+        else:
+            assert co == co2
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/python-xdis-4.1.1/pytest/test_opcode.py 
new/python-xdis-4.1.3/pytest/test_opcode.py
--- old/python-xdis-4.1.1/pytest/test_opcode.py 2019-10-29 13:21:01.000000000 
+0100
+++ new/python-xdis-4.1.3/pytest/test_opcode.py 2019-11-18 01:32:26.000000000 
+0100
@@ -7,21 +7,25 @@
     opmap = dict([(k.replace('+', '_'), v)
                   for (k, v) in dis.opmap.items()])
 
-    # print(set(opmap.items()) - set(opc.opmap.items()))
-    # print(set(opc.opmap.items()) - set(opmap.items()))
+    # print("Extra in dis:", set(opmap.items()) - set(opc.opmap.items()))
+    # print("Extra in xdis:", set(opc.opmap.items()) - set(opmap.items()))
 
     # for item in opmap.items():
     #   assert item in opc.opmap.items(), item
 
+    fields_str = "hascompare hasconst hasfree hasjabs hasjrel haslocal"
     # PyPy 2.7.13 changes opcodes mid-version. It is too complicated
     # to figure out where the change actually occurred
-    if not (IS_PYPY and PYTHON_VERSION == 2.7):
+    # Pypy 3.6.9 may or may not have JUMP_IF_NOT_DEBUG
+    if not (IS_PYPY and PYTHON_VERSION in (2.7, 3.6)):
         assert all(item in opmap.items() for item in opc.opmap.items())
+    elif (IS_PYPY and PYTHON_VERSION == 3.6):
+        # Don't count JUMP_IF_NOT_DEBUG mismatch
+        fields_str = "hascompare hasconst hasfree hasjabs haslocal"
 
     assert all(item in opc.opmap.items() for item in opmap.items())
 
-    fields = """hascompare hasconst hasfree hasjabs hasjrel haslocal
-    hasname""".split()
+    fields = fields_str.split()
     for field in fields:
         opc_set = set(getattr(opc, field))
         dis_set = set(getattr(dis, field))
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/python-xdis-4.1.1/pytest/test_std.py 
new/python-xdis-4.1.3/pytest/test_std.py
--- old/python-xdis-4.1.1/pytest/test_std.py    2019-10-29 13:21:01.000000000 
+0100
+++ new/python-xdis-4.1.3/pytest/test_std.py    2019-11-18 01:32:26.000000000 
+0100
@@ -59,109 +59,110 @@
     expected_dis = EXPECTED_DIS_36
 
 
-@pytest.fixture
-def bytecode_fixture():
-    return dis.Bytecode(TEST_SOURCE_CODE)
+if PYTHON_VERSION >= 3.2:
+    @pytest.fixture
+    def bytecode_fixture():
+        return dis.Bytecode(TEST_SOURCE_CODE)
 
 
-@pytest.fixture
-def traceback_fixture():
-    try:
-        raise Exception
-    except:
-        _, _, tb = sys.exc_info()
-        return tb
+    @pytest.fixture
+    def traceback_fixture():
+        try:
+            raise Exception
+        except:
+            _, _, tb = sys.exc_info()
+            return tb
 
 
-@pytest.yield_fixture
-def stream_fixture():
-    with closing(six.StringIO()) as s:
-        yield s
+    @pytest.yield_fixture
+    def stream_fixture():
+        with closing(six.StringIO()) as s:
+            yield s
 
 
-def test_bytecode_from_traceback(traceback_fixture):
-    assert len(list(dis.Bytecode.from_traceback(traceback_fixture))) > 0
+    def test_bytecode_from_traceback(traceback_fixture):
+        assert len(list(dis.Bytecode.from_traceback(traceback_fixture))) > 0
 
 
-def test_bytecode_codeobj(bytecode_fixture):
-    assert bytecode_fixture.codeobj is not None
+    def test_bytecode_codeobj(bytecode_fixture):
+        assert bytecode_fixture.codeobj is not None
 
 
-def test_bytecode_first_line(bytecode_fixture):
-    assert bytecode_fixture.first_line is not None
+    def test_bytecode_first_line(bytecode_fixture):
+        assert bytecode_fixture.first_line is not None
 
 
-def test_bytecode_dis(bytecode_fixture):
-    assert bytecode_fixture.dis() == expected_dis
+    def test_bytecode_dis(bytecode_fixture):
+        assert bytecode_fixture.dis() == expected_dis
 
 
-def test_bytecode_info(bytecode_fixture):
-    actual = bytecode_fixture.info()
-    assert actual == EXPECTED_CODE_INFO
+    def test_bytecode_info(bytecode_fixture):
+        actual = bytecode_fixture.info()
+        assert actual == EXPECTED_CODE_INFO
 
 
-def test_bytecode__iter__(bytecode_fixture):
-    assert len(list(bytecode_fixture)) > 0
+    def test_bytecode__iter__(bytecode_fixture):
+        assert len(list(bytecode_fixture)) > 0
 
 
-def test_code_info():
-    assert dis.code_info(TEST_SOURCE_CODE) == EXPECTED_CODE_INFO
+    def test_code_info():
+        assert dis.code_info(TEST_SOURCE_CODE) == EXPECTED_CODE_INFO
 
 
-def test_show_code(stream_fixture):
-    dis.show_code(TEST_SOURCE_CODE, file=stream_fixture)
-    actual = stream_fixture.getvalue()
-    assert actual == EXPECTED_CODE_INFO + '\n'
+    def test_show_code(stream_fixture):
+        dis.show_code(TEST_SOURCE_CODE, file=stream_fixture)
+        actual = stream_fixture.getvalue()
+        assert actual == EXPECTED_CODE_INFO + '\n'
 
 
-def test_pretty_flags():
-    assert dis.pretty_flags(1) == '0x00000001 (OPTIMIZED)'
+    def test_pretty_flags():
+        assert dis.pretty_flags(1) == '0x00000001 (OPTIMIZED)'
 
 
-def test_dis(stream_fixture):
-    dis.dis(TEST_SOURCE_CODE, file=stream_fixture)
-    actual = stream_fixture.getvalue()
-    assert actual == expected_dis + '\n'
+    def test_dis(stream_fixture):
+        dis.dis(TEST_SOURCE_CODE, file=stream_fixture)
+        actual = stream_fixture.getvalue()
+        assert actual == expected_dis + '\n'
 
 
-def test_distb(traceback_fixture, stream_fixture):
-    dis.distb(traceback_fixture, file=stream_fixture)
-    actual = stream_fixture.getvalue()
-    actual_len = len(actual)
-    assert actual_len > 0
+    def test_distb(traceback_fixture, stream_fixture):
+        dis.distb(traceback_fixture, file=stream_fixture)
+        actual = stream_fixture.getvalue()
+        actual_len = len(actual)
+        assert actual_len > 0
 
 
-def test_disassemble(stream_fixture):
-    dis.disassemble(TEST_CODE, file=stream_fixture)
-    actual = stream_fixture.getvalue()
-    expected = EXPECTED_CODE_INFO + '\n' + expected_dis + '\n'
-    assert actual == expected
+    def test_disassemble(stream_fixture):
+        dis.disassemble(TEST_CODE, file=stream_fixture)
+        actual = stream_fixture.getvalue()
+        expected = EXPECTED_CODE_INFO + '\n' + expected_dis + '\n'
+        assert actual == expected
 
 
-def test_get_instructions():
-    actual = list(dis.get_instructions(TEST_SOURCE_CODE))
-    actual_len = len(actual)
-    assert actual_len > 0
+    def test_get_instructions():
+        actual = list(dis.get_instructions(TEST_SOURCE_CODE))
+        actual_len = len(actual)
+        assert actual_len > 0
 
 
-@pytest.mark.skipif(IS_PYPY,
-                    reason="Pypy can't be converted to a floating point 
number")
-def test_make_std_api():
-    api24_tup = dis.make_std_api((2, 4, 6, 'final', 0))
-    api24_float = dis.make_std_api(2.4)
-    assert api24_tup.opmap == api24_float.opmap, \
-        "Can get std_api using a floating-point number"
+    @pytest.mark.skipif(IS_PYPY,
+                        reason="Pypy can't be converted to a floating point 
number")
+    def test_make_std_api():
+        api24_tup = dis.make_std_api((2, 4, 6, 'final', 0))
+        api24_float = dis.make_std_api(2.4)
+        assert api24_tup.opmap == api24_float.opmap, \
+            "Can get std_api using a floating-point number"
 
-def test_findlinestarts():
-    actual = list(dis.findlinestarts(TEST_CODE))
-    actual_len = len(actual)
-    assert actual_len > 0
+    def test_findlinestarts():
+        actual = list(dis.findlinestarts(TEST_CODE))
+        actual_len = len(actual)
+        assert actual_len > 0
 
-def test_findlabels():
-    if PYTHON_VERSION < 3.6:
-        test_code = TEST_BRANCH_CODE
-    else:
-        test_code = TEST_BRANCH_CODE.co_code
-    actual = list(dis.findlabels(test_code))
-    actual_len = len(actual)
-    assert actual_len > 0
+    def test_findlabels():
+        if PYTHON_VERSION < 3.6:
+            test_code = TEST_BRANCH_CODE
+        else:
+            test_code = TEST_BRANCH_CODE.co_code
+        actual = list(dis.findlabels(test_code))
+        actual_len = len(actual)
+        assert actual_len > 0
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/python-xdis-4.1.1/requirements-dev.txt 
new/python-xdis-4.1.3/requirements-dev.txt
--- old/python-xdis-4.1.1/requirements-dev.txt  2019-10-29 13:21:01.000000000 
+0100
+++ new/python-xdis-4.1.3/requirements-dev.txt  2019-11-18 01:32:26.000000000 
+0100
@@ -1,6 +1,5 @@
 nose
 flake8
 six
-hypothesis==3.0.0
 pytest==3.2.0
 pytest-runner
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/python-xdis-4.1.1/setup.py 
new/python-xdis-4.1.3/setup.py
--- old/python-xdis-4.1.1/setup.py      2019-10-29 13:21:01.000000000 +0100
+++ new/python-xdis-4.1.3/setup.py      2019-11-18 01:32:26.000000000 +0100
@@ -17,6 +17,7 @@
        entry_points       = entry_points,
        license            = license,
        long_description   = long_description,
+       long_description_content_type = "text/x-rst",
        name               = modname,
        packages           = find_packages(),
        py_modules         = py_modules,
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/python-xdis-4.1.1/test/Makefile 
new/python-xdis-4.1.3/test/Makefile
--- old/python-xdis-4.1.1/test/Makefile 2019-10-29 13:21:01.000000000 +0100
+++ new/python-xdis-4.1.3/test/Makefile 2019-11-18 01:32:26.000000000 +0100
@@ -21,7 +21,8 @@
                   --bytecode-3.2 --bytecode-3.3 \
                   --bytecode-3.4 --bytecode-3.5 \
                  --bytecode-3.6 --bytecode-3.7 \
-                 --bytecode-2.7pypy --bytecode-3.2pypy --bytecode-3.6pypy 
$(COMPILE)
+                 --bytecode-2.7pypy --bytecode-3.2pypy \
+                  --bytecode-3.5pypy --bytecode-3.6pypy $(COMPILE)
 check-short:
        $(PYTHON) test_pyenvlib.py --verify --simple
 
Binary files old/python-xdis-4.1.1/test/bytecode_3.5pypy/00_assign.pyc and 
new/python-xdis-4.1.3/test/bytecode_3.5pypy/00_assign.pyc differ
Binary files old/python-xdis-4.1.1/test/bytecode_3.5pypy/00_import.pyc and 
new/python-xdis-4.1.3/test/bytecode_3.5pypy/00_import.pyc differ
Binary files old/python-xdis-4.1.1/test/bytecode_3.5pypy/11_classbug.pyc and 
new/python-xdis-4.1.3/test/bytecode_3.5pypy/11_classbug.pyc differ
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/python-xdis-4.1.1/test/simple_source/00_import.py 
new/python-xdis-4.1.3/test/simple_source/00_import.py
--- old/python-xdis-4.1.1/test/simple_source/00_import.py       1970-01-01 
01:00:00.000000000 +0100
+++ new/python-xdis-4.1.3/test/simple_source/00_import.py       2019-11-18 
01:32:26.000000000 +0100
@@ -0,0 +1,10 @@
+# Tests all the different kinds of imports
+import sys
+from os import path
+from os import *
+import time as time1, os as os1
+import http.client as httpclient
+if len(__file__) == 0:
+    # a.b.c should force consecutive LOAD_ATTRs
+    import a.b.c as d
+    import stuff0.stuff1.stuff2.stuff3 as stuff3
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/python-xdis-4.1.1/test/simple_source/11_classbug.py 
new/python-xdis-4.1.3/test/simple_source/11_classbug.py
--- old/python-xdis-4.1.1/test/simple_source/11_classbug.py     1970-01-01 
01:00:00.000000000 +0100
+++ new/python-xdis-4.1.3/test/simple_source/11_classbug.py     2019-11-18 
01:32:26.000000000 +0100
@@ -0,0 +1,3 @@
+class _TemplateMetaclass(type):
+    def __init__(cls, name, bases, dct):
+        super(_TemplateMetaclass, cls).__init__(name, bases, dct)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/python-xdis-4.1.1/test/test_pythonlib.py 
new/python-xdis-4.1.3/test/test_pythonlib.py
--- old/python-xdis-4.1.1/test/test_pythonlib.py        2019-10-29 
13:21:01.000000000 +0100
+++ new/python-xdis-4.1.3/test/test_pythonlib.py        2019-11-18 
01:32:26.000000000 +0100
@@ -74,8 +74,8 @@
 for vers in (1.0, 1.1, 1.2, 1.3, 1.4, 1.5, 1.6,
              2.1, 2.2, 2.3, 2.4, 2.5, '2.5dropbox', 2.6, 2.7,
              3.0, 3.1, 3.2, 3.3, 3.4, 3.5, '3.2pypy', '2.7pypy',
-             '3.6pypy',
-             3.6, 3.7):
+             '3.5pypy', '3.6pypy',
+             3.6, 3.7, 3.8):
     bytecode = "bytecode_%s" % vers
     key = "bytecode-%s" % vers
     test_options[key] = (os.path.join(src_dir, bytecode), PYC, bytecode, vers)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/python-xdis-4.1.1/xdis/bytecode.py 
new/python-xdis-4.1.3/xdis/bytecode.py
--- old/python-xdis-4.1.1/xdis/bytecode.py      2019-10-29 13:21:01.000000000 
+0100
+++ new/python-xdis-4.1.3/xdis/bytecode.py      2019-11-18 01:32:26.000000000 
+0100
@@ -446,7 +446,7 @@
                     fields.append('(%s)' % argrepr)
                     argrepr = None
                 elif (self.optype == 'const'
-                      and not re.search('\s', argrepr)):
+                      and not re.search(r'\s', argrepr)):
                     fields.append('(%s)' % argrepr)
                     argrepr = None
                 else:
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/python-xdis-4.1.1/xdis/load.py 
new/python-xdis-4.1.3/xdis/load.py
--- old/python-xdis-4.1.1/xdis/load.py  2019-10-29 13:21:01.000000000 +0100
+++ new/python-xdis-4.1.3/xdis/load.py  2019-11-18 01:32:26.000000000 +0100
@@ -181,7 +181,7 @@
                 timestamp = 0
                 _ = unpack("<I", ts)[0]  # hash word 1
                 _ = unpack("<I", fp.read(4))[0]  # hash word 2
-            elif magic_int in (3394, 3401, 3412):
+            elif magic_int in (3394, 3401, 3412, 3413):
                 timestamp = 0
                 _ = unpack("<I", fp.read(4))[0]  # pep552_bits
             else:
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/python-xdis-4.1.1/xdis/magics.py 
new/python-xdis-4.1.3/xdis/magics.py
--- old/python-xdis-4.1.1/xdis/magics.py        2019-10-29 13:21:01.000000000 
+0100
+++ new/python-xdis-4.1.3/xdis/magics.py        2019-11-18 01:32:26.000000000 
+0100
@@ -22,7 +22,7 @@
 # b'\x03\xf3\r\n' and its value is a canonic version string, like
 # '2.7'
 
-by_version: in this diectionary, the key is a canonic version string like '2.7,
+by_version: in this dictionary, the key is a canonic version string like '2.7,
 and its value is a magic byte string like b'\x03\xf3\r\n' canonic
 name, like '2.7'
 
@@ -35,7 +35,7 @@
 import re, struct, sys
 from xdis import IS_PYPY
 
-IS_PYPY3 = (48, 112, 160)
+IS_PYPY3 = (48, 64, 112, 160, 192)
 
 
 def add_magic_from_int(magic_int, version):
@@ -271,11 +271,13 @@
 add_magic_from_int(3413, "3.8.0rc1+")
 
 # Weird ones
-# WTF? Python 3.2.5 - PyPy 2.3.4  this doesn't follow the rule below
+# WTF? Python 3.2.5 and PyPy have weird magic numbers
 
 add_magic_from_int(48, "3.2a2")
+add_magic_from_int(64, "3.3pypy")
 add_magic_from_int(112, "3.5pypy")  # pypy3.5-c-jit-latest
-add_magic_from_int(160, "3.6pypy")  # '3.6.1 ... PyPy 7.1.0-beta0'
+add_magic_from_int(160, "3.6.1pypy")  # '3.6.1 ... PyPy 7.1.0-beta0'
+add_magic_from_int(192, "3.6pypy")  # '3.6.9 ... PyPy 7.1.0-beta0'
 add_magic_from_int(1011, "2.7.1b3Jython")  # jython
 add_magic_from_int(22138, "2.7.7Pyston")  # 2.7.8pyston, pyston-0.6.0
 
@@ -313,7 +315,7 @@
     "2.7.8 2.7.9 2.7.10 2.7.11 2.7.12 2.7.13 2.7.14 2.7.15 "
     "2.7.15candidate1 "
     "2.7.16 "
-    "2.7.17rc1 2.7.17candidate1",
+    "2.7.17rc1 2.7.17candidate1 2.7.17",
     "2.7",
 )
 add_canonic_versions("3.0 3.0.0 3.0.1", "3.0a5")
@@ -326,7 +328,7 @@
     "3.4 3.4.0 3.4.1 3.4.2 3.4.3 3.4.4 3.4.5 3.4.6 3.4.7 3.4.8 3.4.9 3.4.10", 
"3.4rc2"
 )
 add_canonic_versions("3.5.0 3.5.1", "3.5")
-add_canonic_versions("3.5.2 3.5.3 3.5.4 3.5.5 3.5.6 3.5.7", "3.5.2")
+add_canonic_versions("3.5.2 3.5.3 3.5.4 3.5.5 3.5.6 3.5.7 3.5.8 3.5.9", 
"3.5.2")
 add_canonic_versions(
     "3.6 3.6.0 3.6.1 3.6.2 3.6.3 3.6.4 3.6.5 3.6.6 3.6.7 3.6.8 3.6.9", "3.6rc1"
 )
@@ -334,8 +336,9 @@
 add_canonic_versions("2.7.10pypy 2.7.13pypy", "2.7pypy")
 add_canonic_versions("2.7.3b0Jython", "2.7.1b3Jython")
 add_canonic_versions("3.2.5pypy", "3.2pypy")
+add_canonic_versions("3.3.5pypy", "3.3pypy")
 add_canonic_versions("3.5.3pypy", "3.5pypy")
-add_canonic_versions("3.6.1pypy", "3.6pypy")
+add_canonic_versions("3.6.9pypy", "3.6pypy")
 add_canonic_versions("2.7.8Pyston", "2.7.7Pyston")
 add_canonic_versions("3.7.0alpha3", "3.7.0alpha3")
 add_canonic_versions("3.7 3.7.0beta5 3.7.1 3.7.2 3.7.3 3.7.4 3.7.5", "3.7.0")
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/python-xdis-4.1.1/xdis/op_imports.py 
new/python-xdis-4.1.3/xdis/op_imports.py
--- old/python-xdis-4.1.1/xdis/op_imports.py    2019-10-29 13:21:01.000000000 
+0100
+++ new/python-xdis-4.1.3/xdis/op_imports.py    2019-11-18 01:32:26.000000000 
+0100
@@ -46,6 +46,7 @@
 from xdis.opcodes import opcode_26pypy as opcode_26pypy
 from xdis.opcodes import opcode_27pypy as opcode_27pypy
 from xdis.opcodes import opcode_32pypy as opcode_32pypy
+from xdis.opcodes import opcode_33pypy as opcode_33pypy
 from xdis.opcodes import opcode_35pypy as opcode_35pypy
 from xdis.opcodes import opcode_36pypy as opcode_36pypy
 
@@ -120,6 +121,7 @@
     '2.6pypy':  opcode_26pypy,
     '2.7pypy':  opcode_27pypy,
     '3.2pypy':  opcode_32pypy,
+    '3.3pypy':  opcode_33pypy,
     '3.5pypy':  opcode_35pypy,
     '3.6pypy':  opcode_36pypy,
     '3.6.1pypy':  opcode_36pypy,
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/python-xdis-4.1.1/xdis/opcodes/opcode_32pypy.py 
new/python-xdis-4.1.3/xdis/opcodes/opcode_32pypy.py
--- old/python-xdis-4.1.1/xdis/opcodes/opcode_32pypy.py 2019-10-29 
13:21:01.000000000 +0100
+++ new/python-xdis-4.1.3/xdis/opcodes/opcode_32pypy.py 2019-11-18 
01:32:26.000000000 +0100
@@ -7,8 +7,14 @@
 """
 
 from xdis.opcodes.base import (
-    finalize_opcodes, init_opdata, jrel_op, name_op, nargs_op,
-    varargs_op, update_pj3)
+    finalize_opcodes,
+    init_opdata,
+    jrel_op,
+    name_op,
+    nargs_op,
+    varargs_op,
+    update_pj3,
+)
 
 version = 3.2
 
@@ -21,15 +27,15 @@
 
 # PyPy only
 # ----------
-name_op(l, 'LOOKUP_METHOD',  201,  1, 2)
-nargs_op(l, 'CALL_METHOD', 202, -1, 1)
-l['hasvargs'].append(202)
+name_op(l, "LOOKUP_METHOD", 201, 1, 2)
+nargs_op(l, "CALL_METHOD", 202, -1, 1)
+l["hasvargs"].append(202)
 
 # Used only in single-mode compilation list-comprehension generators
-varargs_op(l, 'BUILD_LIST_FROM_ARG', 203)
+varargs_op(l, "BUILD_LIST_FROM_ARG", 203)
 
 # Used only in assert statements
-jrel_op(l, 'JUMP_IF_NOT_DEBUG',      204, conditional=True)
+jrel_op(l, "JUMP_IF_NOT_DEBUG", 204, conditional=True)
 
 # There are no opcodes to remove or change.
 # If there were, they'd be listed below.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/python-xdis-4.1.1/xdis/opcodes/opcode_33pypy.py 
new/python-xdis-4.1.3/xdis/opcodes/opcode_33pypy.py
--- old/python-xdis-4.1.1/xdis/opcodes/opcode_33pypy.py 1970-01-01 
01:00:00.000000000 +0100
+++ new/python-xdis-4.1.3/xdis/opcodes/opcode_33pypy.py 2019-11-18 
01:32:26.000000000 +0100
@@ -0,0 +1,46 @@
+# (C) Copyright 2019 by Rocky Bernstein
+"""
+PYPY 3.3 opcodes
+
+This is a like Python 3.3's opcode.py with some classification
+of stack usage.
+"""
+
+from xdis.opcodes.base import (
+    finalize_opcodes,
+    init_opdata,
+    jrel_op,
+    name_op,
+    nargs_op,
+    varargs_op,
+    update_pj3,
+)
+
+version = 3.3
+
+import xdis.opcodes.opcode_33 as opcode_33
+
+l = locals()
+init_opdata(l, opcode_33, version, is_pypy=True)
+
+## FIXME: DRY common PYPY opcode additions
+
+# PyPy only
+# ----------
+name_op(l, "LOOKUP_METHOD", 201, 1, 2)
+nargs_op(l, "CALL_METHOD", 202, -1, 1)
+l["hasvargs"].append(202)
+
+# Used only in single-mode compilation list-comprehension generators
+varargs_op(l, "BUILD_LIST_FROM_ARG", 203)
+
+# Used only in assert statements
+jrel_op(l, "JUMP_IF_NOT_DEBUG", 204, conditional=True)
+
+# There are no opcodes to remove or change.
+# If there were, they'd be listed below.
+
+# FIXME remove (fix uncompyle6)
+update_pj3(globals(), l)
+
+finalize_opcodes(l)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/python-xdis-4.1.1/xdis/opcodes/opcode_35pypy.py 
new/python-xdis-4.1.3/xdis/opcodes/opcode_35pypy.py
--- old/python-xdis-4.1.1/xdis/opcodes/opcode_35pypy.py 2019-10-29 
13:21:01.000000000 +0100
+++ new/python-xdis-4.1.3/xdis/opcodes/opcode_35pypy.py 2019-11-18 
01:32:26.000000000 +0100
@@ -7,9 +7,15 @@
 """
 
 from xdis.opcodes.base import (
-    def_op, finalize_opcodes, init_opdata,
-    jrel_op, name_op, nargs_op,
-    varargs_op, update_pj3)
+    def_op,
+    finalize_opcodes,
+    init_opdata,
+    jrel_op,
+    name_op,
+    nargs_op,
+    varargs_op,
+    update_pj3,
+)
 
 version = 3.5
 
@@ -22,17 +28,17 @@
 
 # PyPy only
 # ----------
-def_op(l, 'FORMAT_VALUE',   155)
-def_op(l, 'BUILD_STRING',   157)
-name_op(l, 'LOOKUP_METHOD',  201,  1, 2)
-nargs_op(l, 'CALL_METHOD', 202, -1, 1)
-l['hasvargs'].append(202)
+def_op(l, "FORMAT_VALUE", 155)
+def_op(l, "BUILD_STRING", 157)
+name_op(l, "LOOKUP_METHOD", 201, 1, 2)
+nargs_op(l, "CALL_METHOD", 202, -1, 1)
+l["hasvargs"].append(202)
 
 # Used only in single-mode compilation list-comprehension generators
-varargs_op(l, 'BUILD_LIST_FROM_ARG', 203)
+varargs_op(l, "BUILD_LIST_FROM_ARG", 203)
 
 # Used only in assert statements
-jrel_op(l, 'JUMP_IF_NOT_DEBUG',      204, conditional=True)
+jrel_op(l, "JUMP_IF_NOT_DEBUG", 204, conditional=True)
 
 # There are no opcodes to remove or change.
 # If there were, they'd be listed below.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/python-xdis-4.1.1/xdis/unmarshal.py 
new/python-xdis-4.1.3/xdis/unmarshal.py
--- old/python-xdis-4.1.1/xdis/unmarshal.py     2019-10-29 13:21:01.000000000 
+0100
+++ new/python-xdis-4.1.3/xdis/unmarshal.py     2019-11-18 01:32:26.000000000 
+0100
@@ -29,7 +29,7 @@
 import sys, types
 from struct import unpack
 
-from xdis.magics import PYTHON_MAGIC_INT
+from xdis.magics import PYTHON_MAGIC_INT, IS_PYPY3
 from xdis.code import Code2, Code3, Code38, Code2Compat
 from xdis import PYTHON3, PYTHON_VERSION, IS_PYPY
 
@@ -47,13 +47,7 @@
 
 
 def compat_str(s):
-    if (
-        PYTHON_VERSION > 3.2
-        or
-        # FIXME: investigate
-        PYTHON_VERSION == 3.2
-        and IS_PYPY
-    ):
+    if PYTHON3:
         try:
             return s.decode("utf-8")
         except UnicodeDecodeError:
@@ -61,7 +55,6 @@
             # and it will get converted to str when needed
             return s
 
-    elif PYTHON3:
         return s.decode()
     else:
         return str(s)
@@ -122,6 +115,7 @@
 def load_code_type(fp, magic_int, bytes_for_s=False, code_objects={}):
     # FIXME: use tables to simplify this?
     # Python [1.0 .. 2.2)
+
     v10_to_12 = magic_int in (39170, 39171)
 
     # FIXME: find out what magics were for 1.3
@@ -140,12 +134,12 @@
     else:
         co_argcount = unpack("<i", fp.read(4))[0]
 
-    if magic_int in (3412,):
+    if magic_int in (3412, 3413):
         co_posonlyargcount = unpack("<i", fp.read(4))[0]
     else:
         co_posonlyargcount = None
 
-    if ((3020 < magic_int < 20121) or magic_int in (160,)) and not v11_to_14:
+    if ((3020 < magic_int < 20121) or magic_int in (64, 160, 112, 192)) and 
not v11_to_14:
         kwonlyargcount = unpack("<i", fp.read(4))[0]
     else:
         kwonlyargcount = 0
@@ -214,7 +208,7 @@
     # bytes (which is probably more logical).
     if PYTHON3:
         Code = types.CodeType
-        if PYTHON_MAGIC_INT > 3020:
+        if PYTHON_MAGIC_INT > 3020 or PYTHON_MAGIC_INT in IS_PYPY3:
             # Check for Python 3 interpreter reading Python 2 bytecode.
             # Python 3's code objects are bytes while Python 2's are strings.
             #
@@ -378,7 +372,7 @@
                 co_filename = str(co_filename)
                 co_name = str(co_name)
 
-            if 3020 < magic_int <= 20121:
+            if 3020 < magic_int <= 20121 or magic_int in IS_PYPY3:
                 code = Code3(
                     co_argcount,
                     kwonlyargcount,
@@ -397,10 +391,13 @@
                     co_cellvars,
                 )
             else:
-                if magic_int in (160,):
+                if magic_int in (160, 192):
                     co_filename = str(co_filename)
                     co_name = str(co_name)
                     co_varnames = tuple([str(t) for t in co_varnames])
+                    co_consts = tuple([str(t) for t in co_consts])
+                    co_freevars = tuple([str(t) for t in co_freevars])
+                    co_cellvars = tuple([str(t) for t in co_cellvars])
 
                 Code = types.CodeType
                 code = Code(
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/python-xdis-4.1.1/xdis/verify.py 
new/python-xdis-4.1.3/xdis/verify.py
--- old/python-xdis-4.1.1/xdis/verify.py        2019-10-29 13:21:01.000000000 
+0100
+++ new/python-xdis-4.1.3/xdis/verify.py        2019-11-18 01:32:26.000000000 
+0100
@@ -93,9 +93,9 @@
     f.close
 
     if PYTHON_VERSION == 3.2 and IS_PYPY:
-        assert bytes1[4:] == bytes2[4:], ("byteode:\n%s\nvs\n%s" % 
(bytes1[4:], bytes2[4:]))
+        assert bytes1[4:] == bytes2[4:], ("bytecode:\n%s\nvs\n%s" % 
(bytes1[4:], bytes2[4:]))
     else:
-        assert bytes1 == bytes2, ("byteode:\n%s\nvs\n%s" % (bytes1, bytes2))
+        assert bytes1 == bytes2, ("bytecode:\n%s\nvs\n%s" % (bytes1, bytes2))
 
 def verify_file(real_source_filename, real_bytecode_filename):
     """Compile *real_source_filename* using
@@ -116,8 +116,13 @@
     if not os.path.exists(real_source_filename):
         return
 
-    if PYTHON_VERSION < 3.5:
+    if PYTHON_VERSION < 3.0:
         f = open(real_source_filename, 'U')
+    elif PYTHON_VERSION == 3.0:
+        # Too hard to get working on 3.0
+        return
+    elif 3.1 <= PYTHON_VERSION <= 3.4:
+        f = open(real_source_filename, "rb")
     else:
         f = open(real_source_filename, newline=None, errors='backslashreplace')
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/python-xdis-4.1.1/xdis/version.py 
new/python-xdis-4.1.3/xdis/version.py
--- old/python-xdis-4.1.1/xdis/version.py       2019-10-29 13:21:01.000000000 
+0100
+++ new/python-xdis-4.1.3/xdis/version.py       2019-11-18 01:32:26.000000000 
+0100
@@ -1,3 +1,3 @@
 # This file is suitable for sourcing inside bash as
 # well as importing into Python
-VERSION='4.1.1'
+VERSION='4.1.3'


Reply via email to