Hello community, here is the log from the commit of package python3 for openSUSE:Factory checked in at 2019-01-28 20:45:26 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/python3 (Old) and /work/SRC/openSUSE:Factory/.python3.new.28833 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "python3" Mon Jan 28 20:45:26 2019 rev:90 rq:663711 version:3.7.2 Changes: -------- --- /work/SRC/openSUSE:Factory/python3/python3-base.changes 2018-04-29 19:37:02.311094531 +0200 +++ /work/SRC/openSUSE:Factory/.python3.new.28833/python3-base.changes 2019-01-28 20:45:29.586091526 +0100 @@ -1,0 +2,266 @@ +Tue Jan 8 12:51:01 UTC 2019 - Tomáš Chvátal <[email protected]> + +- Do not require full gettext in order to avoid pulling in the + glib2 as a dependency + +------------------------------------------------------------------- +Tue Jan 8 12:25:27 UTC 2019 - Tomáš Chvátal <[email protected]> + +- Update to 3.7.2: + * bugfix release: + https://docs.python.org/3.7/whatsnew/changelog.html#changelog + +------------------------------------------------------------------- +Wed Jan 2 12:51:48 CET 2019 - [email protected] + +- Stop applying python-3.6.0-multilib-new.patch (which is still + WIP), and apply the old proven python-3.6.0-multilib.patch + instead. + +------------------------------------------------------------------- +Wed Dec 19 19:29:44 UTC 2018 - Todd R <[email protected]> + +- Use upstream-recommended %{_rpmconfigdir}/macros.d directory + for the rpm macros. + +------------------------------------------------------------------- +Mon Dec 17 17:24:49 CET 2018 - [email protected] + +- Upgrade to 3.7.2rc1: + * bugfix release, for the full list of all changes see + https://docs.python.org/3.7/whatsnew/changelog.html#changelog +- Make run of the test suite more verbose + +------------------------------------------------------------------- +Tue Dec 11 01:52:45 UTC 2018 - Jan Engelhardt <[email protected]> + +- Write summaries without em dashes. + +------------------------------------------------------------------- +Mon Dec 3 13:27:54 UTC 2018 - Matěj Cepl <[email protected]> + +- Remove python-3.3.0b1-curses-panel.patch it is unnecessary anymore. +- Add boo1071941-make-install-in-sep-loc.patch to make pip and + distutils in user environment install into separate location + (boo#1071941) + + Set values of prefix and exec_prefix in distutils install + command to /usr/local if executable is /usr/bin/python* and RPM + build is not detected to make pip and distutils install into + separate location +- Remove finally python-3.3.3-skip-distutils-test_sysconfig_module.patch +- Remove distutils-reproducible-compile.patch which doesn't make + really much difference in reproducibility (see + gh#python/cpython#8057 and discussion there). + +------------------------------------------------------------------- +Sat Dec 1 00:14:28 CET 2018 - [email protected] + +- Rename Stop_hash-based_invalidation_w_SOURCE_DATE_EPOCH.patch + to bpo34022-stop_hash-based_invalidation_w_SOURCE_DATE_EPOCH.patch + +------------------------------------------------------------------- +Wed Nov 7 12:10:41 CET 2018 - [email protected] + +- Add dependency on bluez-devel to build support for Bluetooth + (boo#1109998) + +------------------------------------------------------------------- +Tue Nov 6 13:52:45 CET 2018 - [email protected] + +- Add devhelp subpackage and split qthelp into another + subpackage. + +------------------------------------------------------------------- +Wed Oct 24 12:38:00 UTC 2018 - Matěj Cepl <[email protected]> + +- Remove python-3.0b1-record-rpm.patch and + Python-3.0b1-record-rpm.patch, as they are not needed anymore + +------------------------------------------------------------------- +Tue Oct 23 14:14:16 UTC 2018 - Matej Cepl <[email protected]> + +- Switch off test_threading for optimization builds. + +------------------------------------------------------------------- +Mon Oct 22 14:41:59 CEST 2018 - [email protected] + +- Update to python-3.7.1. This is just a brief overview, complete + changelog available at + https://docs.python.org/3.7/whatsnew/changelog.html#python-3-7-1-final: + Library + bpo-34970: Protect tasks weak set manipulation in asyncio.all_tasks() +- Patches already accepted upstream are removed: + * 00307-allow-to-call-Py_Main-after-Py_Initialize.patch + * 00308-tls-1.3.patch +- New patches added: + * Stop_hash-based_invalidation_w_SOURCE_DATE_EPOCH.patch + * raise_SIGING_not_handled.patch +- All other patches refreshed via quilt. + +------------------------------------------------------------------- +Mon Oct 22 12:22:19 UTC 2018 - Matej Cepl <[email protected]> + +- Add raise_SIGING_not_handled.patch to fix bsc#1094814 + +------------------------------------------------------------------- +Wed Oct 17 14:04:35 UTC 2018 - Tomáš Chvátal <[email protected]> + +- Add patch to fix importlib return types: + * python3-imp-returntype.patch + +------------------------------------------------------------------- +Mon Oct 15 13:46:32 CEST 2018 - [email protected] + +- bpo-34022 still not completely fixed, so we have to keep + excluding test_cmd_line_script, + test_multiprocessing_main_handling, and test_runpy from the + test suite. + +------------------------------------------------------------------- +Sun Oct 14 15:57:24 UTC 2018 - Matej Cepl <[email protected]> + +- Update to python 3.7.1~rc2: + Core and Builtins + bpo-34879: Fix a possible null pointer dereference in + bytesobject.c. Patch by Zackery Spytz. + bpo-34854: Fixed a crash in compiling string annotations + containing a lambda with a keyword-only argument that + doesn’t have a default value. + bpo-34320: Fix dict(od) didn’t copy iteration order of + OrderedDict. + Library + bpo-34769: Fix for async generators not finalizing when event + loop is in debug mode and garbage collector runs in another + thread. + bpo-34922: Fixed integer overflow in the digest() and + hexdigest() methods for the SHAKE algorithm in the hashlib + module. + bpo-34900: Fixed unittest.TestCase.debug() when used to call + test methods with subtests. Patch by Bruno Oliveira. + bpo-34871: Fix inspect module polluted sys.modules when parsing + __text_signature__ of callable. + bpo-34872: Fix self-cancellation in C implementation of + asyncio.Task + bpo-34819: Use a monotonic clock to compute timeouts in + Executor.map() and as_completed(), in order to prevent + timeouts from deviating when the system clock is adjusted. + bpo-34334: In QueueHandler, clear exc_text from LogRecord to + prevent traceback from being written twice. + bpo-6721: Acquire the logging module’s commonly used internal + locks while fork()ing to avoid deadlocks in the child + process. + bpo-34172: Fix a reference issue inside multiprocessing.Pool + that caused the pool to remain alive if it was deleted + without being closed or terminated explicitly. + Documentation + bpo-32174: chm document displays non-ASCII charaters properly on + some MBCS Windows systems. + Tests + bpo-32962: Fixed test_gdb when Python is compiled with flags + -mcet -fcf-protection -O0. + C API + bpo-34910: Ensure that PyObject_Print() always returns -1 on + error. Patch by Zackery Spytz. + +------------------------------------------------------------------- +Fri Oct 12 20:46:58 CEST 2018 - [email protected] + +- Add Stop_hash-based_invalidation_w_SOURCE_DATE_EPOCH.patch to + fix problems with SOURCE_DATE_EPOCH variable (bpo-34022) + +------------------------------------------------------------------- +Mon Sep 17 09:44:02 UTC 2018 - Tomáš Chvátal <[email protected]> + +- Add patch to fix build with tls1.3 supported openssl + * 00308-tls-1.3.patch +- Add patch to fix Py_Main calls after Py_initialize + * 00307-allow-to-call-Py_Main-after-Py_Initialize.patch + +------------------------------------------------------------------- +Mon Sep 3 15:22:42 UTC 2018 - Matěj Cepl <[email protected]> + +- Add -fwrapv to OPTS, which is default for python3 anyway + See for example https://github.com/zopefoundation/persistent/issues/86 + for bugs which are caused by avoiding it. + +------------------------------------------------------------------- +Tue Jul 10 11:12:32 UTC 2018 - [email protected] + +- Fix ownership of _contextvars, _queue, and _xxtestfuzz + +------------------------------------------------------------------- +Tue Jul 3 15:04:48 UTC 2018 - [email protected] + +- Switch off LTO for distros with older GCC +- Fix %files + ++++ 162 more lines (skipped) ++++ between /work/SRC/openSUSE:Factory/python3/python3-base.changes ++++ and /work/SRC/openSUSE:Factory/.python3.new.28833/python3-base.changes --- /work/SRC/openSUSE:Factory/python3/python3-doc.changes 2018-04-05 15:30:06.331485479 +0200 +++ /work/SRC/openSUSE:Factory/.python3.new.28833/python3-doc.changes 2019-01-28 20:45:29.630091480 +0100 @@ -1 +1,289 @@ --------------------------------------------------------------------- +------------------------------------------------------------------- +Tue Jan 8 12:51:01 UTC 2019 - Tomáš Chvátal <[email protected]> + +- Do not require full gettext in order to avoid pulling in the + glib2 as a dependency + +------------------------------------------------------------------- +Tue Jan 8 12:25:27 UTC 2019 - Tomáš Chvátal <[email protected]> + +- Update to 3.7.2: + * bugfix release: + https://docs.python.org/3.7/whatsnew/changelog.html#changelog + +------------------------------------------------------------------- +Wed Jan 2 12:51:48 CET 2019 - [email protected] + +- Stop applying python-3.6.0-multilib-new.patch (which is still + WIP), and apply the old proven python-3.6.0-multilib.patch + instead. + +------------------------------------------------------------------- +Wed Dec 19 19:29:44 UTC 2018 - Todd R <[email protected]> + +- Use upstream-recommended %{_rpmconfigdir}/macros.d directory + for the rpm macros. + +------------------------------------------------------------------- +Mon Dec 17 17:24:49 CET 2018 - [email protected] + +- Upgrade to 3.7.2rc1: + * bugfix release, for the full list of all changes see + https://docs.python.org/3.7/whatsnew/changelog.html#changelog +- Make run of the test suite more verbose + +------------------------------------------------------------------- +Tue Dec 11 01:52:45 UTC 2018 - Jan Engelhardt <[email protected]> + +- Write summaries without em dashes. + +------------------------------------------------------------------- +Mon Dec 3 13:27:54 UTC 2018 - Matěj Cepl <[email protected]> + +- Remove python-3.3.0b1-curses-panel.patch it is unnecessary anymore. +- Add boo1071941-make-install-in-sep-loc.patch to make pip and + distutils in user environment install into separate location + (boo#1071941) + + Set values of prefix and exec_prefix in distutils install + command to /usr/local if executable is /usr/bin/python* and RPM + build is not detected to make pip and distutils install into + separate location +- Remove finally python-3.3.3-skip-distutils-test_sysconfig_module.patch +- Remove distutils-reproducible-compile.patch which doesn't make + really much difference in reproducibility (see + gh#python/cpython#8057 and discussion there). + +------------------------------------------------------------------- +Sat Dec 1 00:14:28 CET 2018 - [email protected] + +- Rename Stop_hash-based_invalidation_w_SOURCE_DATE_EPOCH.patch + to bpo34022-stop_hash-based_invalidation_w_SOURCE_DATE_EPOCH.patch + +------------------------------------------------------------------- +Wed Nov 7 12:10:41 CET 2018 - [email protected] + +- Add dependency on bluez-devel to build support for Bluetooth + (boo#1109998) + +------------------------------------------------------------------- +Tue Nov 6 13:52:45 CET 2018 - [email protected] + +- Add devhelp subpackage and split qthelp into another + subpackage. + +------------------------------------------------------------------- +Wed Oct 24 12:38:00 UTC 2018 - Matěj Cepl <[email protected]> + +- Remove python-3.0b1-record-rpm.patch and + Python-3.0b1-record-rpm.patch, as they are not needed anymore + +------------------------------------------------------------------- +Tue Oct 23 14:14:16 UTC 2018 - Matej Cepl <[email protected]> + +- Switch off test_threading for optimization builds. + +------------------------------------------------------------------- +Mon Oct 22 14:41:59 CEST 2018 - [email protected] + +- Update to python-3.7.1. This is just a brief overview, complete + changelog available at + https://docs.python.org/3.7/whatsnew/changelog.html#python-3-7-1-final: + Library + bpo-34970: Protect tasks weak set manipulation in asyncio.all_tasks() +- Patches already accepted upstream are removed: + * 00307-allow-to-call-Py_Main-after-Py_Initialize.patch + * 00308-tls-1.3.patch +- New patches added: + * Stop_hash-based_invalidation_w_SOURCE_DATE_EPOCH.patch + * raise_SIGING_not_handled.patch +- All other patches refreshed via quilt. + +------------------------------------------------------------------- +Mon Oct 22 12:22:19 UTC 2018 - Matej Cepl <[email protected]> + +- Add raise_SIGING_not_handled.patch to fix bsc#1094814 + +------------------------------------------------------------------- +Wed Oct 17 14:04:35 UTC 2018 - Tomáš Chvátal <[email protected]> + +- Add patch to fix importlib return types: + * python3-imp-returntype.patch + +------------------------------------------------------------------- +Mon Oct 15 13:46:32 CEST 2018 - [email protected] + +- bpo-34022 still not completely fixed, so we have to keep + excluding test_cmd_line_script, + test_multiprocessing_main_handling, and test_runpy from the + test suite. + +------------------------------------------------------------------- +Sun Oct 14 15:57:24 UTC 2018 - Matej Cepl <[email protected]> + +- Update to python 3.7.1~rc2: + Core and Builtins + bpo-34879: Fix a possible null pointer dereference in + bytesobject.c. Patch by Zackery Spytz. + bpo-34854: Fixed a crash in compiling string annotations + containing a lambda with a keyword-only argument that + doesn’t have a default value. + bpo-34320: Fix dict(od) didn’t copy iteration order of + OrderedDict. + Library + bpo-34769: Fix for async generators not finalizing when event + loop is in debug mode and garbage collector runs in another + thread. + bpo-34922: Fixed integer overflow in the digest() and + hexdigest() methods for the SHAKE algorithm in the hashlib + module. + bpo-34900: Fixed unittest.TestCase.debug() when used to call + test methods with subtests. Patch by Bruno Oliveira. + bpo-34871: Fix inspect module polluted sys.modules when parsing + __text_signature__ of callable. + bpo-34872: Fix self-cancellation in C implementation of + asyncio.Task + bpo-34819: Use a monotonic clock to compute timeouts in + Executor.map() and as_completed(), in order to prevent + timeouts from deviating when the system clock is adjusted. + bpo-34334: In QueueHandler, clear exc_text from LogRecord to + prevent traceback from being written twice. + bpo-6721: Acquire the logging module’s commonly used internal + locks while fork()ing to avoid deadlocks in the child + process. + bpo-34172: Fix a reference issue inside multiprocessing.Pool + that caused the pool to remain alive if it was deleted + without being closed or terminated explicitly. + Documentation + bpo-32174: chm document displays non-ASCII charaters properly on + some MBCS Windows systems. + Tests + bpo-32962: Fixed test_gdb when Python is compiled with flags + -mcet -fcf-protection -O0. + C API + bpo-34910: Ensure that PyObject_Print() always returns -1 on + error. Patch by Zackery Spytz. + +------------------------------------------------------------------- +Fri Oct 12 20:46:58 CEST 2018 - [email protected] + +- Add Stop_hash-based_invalidation_w_SOURCE_DATE_EPOCH.patch to + fix problems with SOURCE_DATE_EPOCH variable (bpo-34022) + +------------------------------------------------------------------- +Mon Sep 17 09:44:02 UTC 2018 - Tomáš Chvátal <[email protected]> + +- Add patch to fix build with tls1.3 supported openssl + * 00308-tls-1.3.patch +- Add patch to fix Py_Main calls after Py_initialize + * 00307-allow-to-call-Py_Main-after-Py_Initialize.patch + +------------------------------------------------------------------- +Mon Sep 3 15:22:42 UTC 2018 - Matěj Cepl <[email protected]> + +- Add -fwrapv to OPTS, which is default for python3 anyway + See for example https://github.com/zopefoundation/persistent/issues/86 + for bugs which are caused by avoiding it. + +------------------------------------------------------------------- +Tue Jul 10 11:12:32 UTC 2018 - [email protected] + +- Fix ownership of _contextvars, _queue, and _xxtestfuzz + +------------------------------------------------------------------- +Tue Jul 3 15:04:48 UTC 2018 - [email protected] + +- Switch off LTO for distros with older GCC ++++ 861 more lines (skipped) ++++ between /work/SRC/openSUSE:Factory/python3/python3-doc.changes ++++ and /work/SRC/openSUSE:Factory/.python3.new.28833/python3-doc.changes --- /work/SRC/openSUSE:Factory/python3/python3.changes 2018-05-06 14:57:17.106237337 +0200 +++ /work/SRC/openSUSE:Factory/.python3.new.28833/python3.changes 2019-01-28 20:45:29.678091429 +0100 @@ -1,0 +2,261 @@ +Tue Jan 8 12:51:01 UTC 2019 - Tomáš Chvátal <[email protected]> + +- Do not require full gettext in order to avoid pulling in the + glib2 as a dependency + +------------------------------------------------------------------- +Tue Jan 8 12:25:27 UTC 2019 - Tomáš Chvátal <[email protected]> + +- Update to 3.7.2: + * bugfix release: + https://docs.python.org/3.7/whatsnew/changelog.html#changelog + +------------------------------------------------------------------- +Wed Jan 2 12:51:48 CET 2019 - [email protected] + +- Stop applying python-3.6.0-multilib-new.patch (which is still + WIP), and apply the old proven python-3.6.0-multilib.patch + instead. + +------------------------------------------------------------------- +Wed Dec 19 19:29:44 UTC 2018 - Todd R <[email protected]> + +- Use upstream-recommended %{_rpmconfigdir}/macros.d directory + for the rpm macros. + +------------------------------------------------------------------- +Mon Dec 17 17:24:49 CET 2018 - [email protected] + +- Upgrade to 3.7.2rc1: + * bugfix release, for the full list of all changes see + https://docs.python.org/3.7/whatsnew/changelog.html#changelog +- Make run of the test suite more verbose + +------------------------------------------------------------------- +Tue Dec 11 01:52:45 UTC 2018 - Jan Engelhardt <[email protected]> + +- Write summaries without em dashes. + +------------------------------------------------------------------- +Mon Dec 3 13:27:54 UTC 2018 - Matěj Cepl <[email protected]> + +- Remove python-3.3.0b1-curses-panel.patch it is unnecessary anymore. +- Add boo1071941-make-install-in-sep-loc.patch to make pip and + distutils in user environment install into separate location + (boo#1071941) + + Set values of prefix and exec_prefix in distutils install + command to /usr/local if executable is /usr/bin/python* and RPM + build is not detected to make pip and distutils install into + separate location +- Remove finally python-3.3.3-skip-distutils-test_sysconfig_module.patch +- Remove distutils-reproducible-compile.patch which doesn't make + really much difference in reproducibility (see + gh#python/cpython#8057 and discussion there). + +------------------------------------------------------------------- +Sat Dec 1 00:14:28 CET 2018 - [email protected] + +- Rename Stop_hash-based_invalidation_w_SOURCE_DATE_EPOCH.patch + to bpo34022-stop_hash-based_invalidation_w_SOURCE_DATE_EPOCH.patch + +------------------------------------------------------------------- +Wed Nov 7 12:10:41 CET 2018 - [email protected] + +- Add dependency on bluez-devel to build support for Bluetooth + (boo#1109998) + +------------------------------------------------------------------- +Tue Nov 6 13:52:45 CET 2018 - [email protected] + +- Add devhelp subpackage and split qthelp into another + subpackage. + +------------------------------------------------------------------- +Wed Oct 24 12:38:00 UTC 2018 - Matěj Cepl <[email protected]> + +- Remove python-3.0b1-record-rpm.patch and + Python-3.0b1-record-rpm.patch, as they are not needed anymore + +------------------------------------------------------------------- +Tue Oct 23 14:14:16 UTC 2018 - Matej Cepl <[email protected]> + +- Switch off test_threading for optimization builds. + +------------------------------------------------------------------- +Mon Oct 22 14:41:59 CEST 2018 - [email protected] + +- Update to python-3.7.1. This is just a brief overview, complete + changelog available at + https://docs.python.org/3.7/whatsnew/changelog.html#python-3-7-1-final: + Library + bpo-34970: Protect tasks weak set manipulation in asyncio.all_tasks() +- Patches already accepted upstream are removed: + * 00307-allow-to-call-Py_Main-after-Py_Initialize.patch + * 00308-tls-1.3.patch +- New patches added: + * Stop_hash-based_invalidation_w_SOURCE_DATE_EPOCH.patch + * raise_SIGING_not_handled.patch +- All other patches refreshed via quilt. + +------------------------------------------------------------------- +Mon Oct 22 12:22:19 UTC 2018 - Matej Cepl <[email protected]> + +- Add raise_SIGING_not_handled.patch to fix bsc#1094814 + +------------------------------------------------------------------- +Wed Oct 17 14:04:35 UTC 2018 - Tomáš Chvátal <[email protected]> + +- Add patch to fix importlib return types: + * python3-imp-returntype.patch + +------------------------------------------------------------------- +Mon Oct 15 13:46:32 CEST 2018 - [email protected] + +- bpo-34022 still not completely fixed, so we have to keep + excluding test_cmd_line_script, + test_multiprocessing_main_handling, and test_runpy from the + test suite. + +------------------------------------------------------------------- +Sun Oct 14 15:57:24 UTC 2018 - Matej Cepl <[email protected]> + +- Update to python 3.7.1~rc2: + Core and Builtins + bpo-34879: Fix a possible null pointer dereference in + bytesobject.c. Patch by Zackery Spytz. + bpo-34854: Fixed a crash in compiling string annotations + containing a lambda with a keyword-only argument that + doesn’t have a default value. + bpo-34320: Fix dict(od) didn’t copy iteration order of + OrderedDict. + Library + bpo-34769: Fix for async generators not finalizing when event + loop is in debug mode and garbage collector runs in another + thread. + bpo-34922: Fixed integer overflow in the digest() and + hexdigest() methods for the SHAKE algorithm in the hashlib + module. + bpo-34900: Fixed unittest.TestCase.debug() when used to call + test methods with subtests. Patch by Bruno Oliveira. + bpo-34871: Fix inspect module polluted sys.modules when parsing + __text_signature__ of callable. + bpo-34872: Fix self-cancellation in C implementation of + asyncio.Task + bpo-34819: Use a monotonic clock to compute timeouts in + Executor.map() and as_completed(), in order to prevent + timeouts from deviating when the system clock is adjusted. + bpo-34334: In QueueHandler, clear exc_text from LogRecord to + prevent traceback from being written twice. + bpo-6721: Acquire the logging module’s commonly used internal + locks while fork()ing to avoid deadlocks in the child + process. + bpo-34172: Fix a reference issue inside multiprocessing.Pool + that caused the pool to remain alive if it was deleted + without being closed or terminated explicitly. + Documentation + bpo-32174: chm document displays non-ASCII charaters properly on + some MBCS Windows systems. + Tests + bpo-32962: Fixed test_gdb when Python is compiled with flags + -mcet -fcf-protection -O0. + C API + bpo-34910: Ensure that PyObject_Print() always returns -1 on + error. Patch by Zackery Spytz. + +------------------------------------------------------------------- +Fri Oct 12 20:46:58 CEST 2018 - [email protected] + +- Add Stop_hash-based_invalidation_w_SOURCE_DATE_EPOCH.patch to + fix problems with SOURCE_DATE_EPOCH variable (bpo-34022) + +------------------------------------------------------------------- +Mon Sep 17 09:44:02 UTC 2018 - Tomáš Chvátal <[email protected]> + +- Add patch to fix build with tls1.3 supported openssl + * 00308-tls-1.3.patch +- Add patch to fix Py_Main calls after Py_initialize + * 00307-allow-to-call-Py_Main-after-Py_Initialize.patch + +------------------------------------------------------------------- +Mon Sep 3 15:22:42 UTC 2018 - Matěj Cepl <[email protected]> + +- Add -fwrapv to OPTS, which is default for python3 anyway + See for example https://github.com/zopefoundation/persistent/issues/86 + for bugs which are caused by avoiding it. + +------------------------------------------------------------------- +Tue Jul 10 11:12:32 UTC 2018 - [email protected] + +- Fix ownership of _contextvars, _queue, and _xxtestfuzz + +------------------------------------------------------------------- +Tue Jul 3 15:04:48 UTC 2018 - [email protected] + +- Switch off LTO for distros with older GCC +- Fix %files + ++++ 749 more lines (skipped) ++++ between /work/SRC/openSUSE:Factory/python3/python3.changes ++++ and /work/SRC/openSUSE:Factory/.python3.new.28833/python3.changes Old: ---- 0001-allow-for-reproducible-builds-of-python-packages.patch Python-3.0b1-record-rpm.patch Python-3.6.5.tar.xz Python-3.6.5.tar.xz.asc distutils-reproducible-compile.patch python-3.3.0b1-curses-panel.patch python-3.3.3-skip-distutils-test_sysconfig_module.patch python-3.6.0-multilib-new.patch python3-rpmlintrc python3-sorted_tar.patch New: ---- Python-3.7.2.tar.xz Python-3.7.2.tar.xz.asc boo1071941-make-install-in-sep-loc.patch bpo34022-stop_hash-based_invalidation_w_SOURCE_DATE_EPOCH.patch python-3.6.0-multilib.patch python3-base-rpmlintrc python3-imp-returntype.patch raise_SIGING_not_handled.patch ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ python3-base.spec ++++++ --- /var/tmp/diff_new_pack.6ULy7L/_old 2019-01-28 20:45:30.918090125 +0100 +++ /var/tmp/diff_new_pack.6ULy7L/_new 2019-01-28 20:45:30.922090121 +0100 @@ -1,7 +1,7 @@ # # spec file for package python3-base # -# Copyright (c) 2018 SUSE LINUX GmbH, Nuernberg, Germany. +# Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany. # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -12,7 +12,7 @@ # license that conforms to the Open Source Definition (Version 1.9) # published by the Open Source Initiative. -# Please submit bugfixes or comments via http://bugs.opensuse.org/ +# Please submit bugfixes or comments via https://bugs.opensuse.org/ # @@ -27,9 +27,9 @@ %define tarname Python-%{tarversion} # the versions are autogenerated from pre_checkin.sh # based on the current source tarball -%define python_version 3.6 -%define python_version_abitag 36 -%define python_version_soname 3_6 +%define python_version 3.7 +%define python_version_abitag 37 +%define python_version_soname 3_7 %define sitedir %{_libdir}/python%{python_version} # three possible ABI kinds: m - pymalloc, d - debug build; see PEP 3149 %define abi_kind m @@ -58,13 +58,13 @@ ### COMMON-DEF-END ### # that thing where "without" means "default=on" and vice versa %bcond_without testsuite -%if 0%{?do_profiling} +# %%if 0%%{?do_profiling} %bcond_without profileopt -%else -%bcond_with profileopt -%endif +# %%else +# %%bcond_with profileopt +# %%endif Name: python3-base -Version: 3.6.5 +Version: 3.7.2 Release: 0 Summary: Python 3 Interpreter and Stdlib Core License: Python-2.0 @@ -83,7 +83,7 @@ # They are listed here to work around missing functionality in rpmbuild, # which would otherwise exclude them from distributed src.rpm files. Source100: PACKAGING-NOTES -Source101: python3-rpmlintrc +Source101: python3-base-rpmlintrc Source102: pre_checkin.sh Source103: skipped_tests.py ##### REQURES, PROVIDES, OBSOLETES ##### @@ -116,13 +116,18 @@ BuildRequires: libexpat-devel # _ctypes BuildRequires: libffi-devel -# nis -BuildRequires: libnsl-devel +# Installed libnsl-devel leads to build failures on nismodule.o +# https://bugs.python.org/issue32007 +# %%if 0%%{?sle_version} >= 1500 && 0%%{?is_opensuse} +# # nis +# BuildRequires: libnsl-devel +# %%endif # _lzma BuildRequires: lzma-devel # ssl BuildRequires: openssl-devel >= 1.0.2 # zlib +BuildRequires: libuuid-devel BuildRequires: zlib-devel # /SECTION # SECTION required for build and testsuite @@ -134,30 +139,35 @@ BuildRequires: xz # /SECTION ### COMMON-PATCH-BEGIN ### -# implement "--record-rpm" option for distutils installations -Patch01: Python-3.0b1-record-rpm.patch # support lib-vs-lib64 distinction -Patch02: python-3.6.0-multilib-new.patch +# New version from https://bugs.python.org/issue34032 +# Patch02: python-3.6.0-multilib-new.patch +# Unfortunately, the new version is still broken, so we have to use the +# old one +Patch02: python-3.6.0-multilib.patch # support finding packages in /usr/local, install to /usr/local by default Patch04: python-3.3.0b1-localpath.patch # replace DATE, TIME and COMPILER by fixed definitions to aid reproducible builds Patch06: python-3.3.0b1-fix_date_time_compiler.patch -# fix wrong include path in curses-panel module -Patch07: python-3.3.0b1-curses-panel.patch # POSIX_FADV_WILLNEED throws EINVAL. Use a different constant in test Patch09: python-3.3.0b1-test-posix_fadvise.patch -# Disable global and distutils sysconfig comparison test, we deviate from the default depending on optflags -Patch12: python-3.3.3-skip-distutils-test_sysconfig_module.patch # Raise timeout value for test_subprocess Patch15: subprocess-raise-timeout.patch -# PATCH-FIX-UPSTREAM [email protected] -- https://github.com/python/cpython/pull/296 -Patch21: 0001-allow-for-reproducible-builds-of-python-packages.patch -# PATCH-FEATURE-OPENSUSE order files for compilation until the underlying cause of bsc#1049186 is resolved -Patch22: distutils-reproducible-compile.patch # skip some tests only for PowerPC Patch23: skip_random_failing_tests.patch -# PATCH-FIX-UPSTREAM sorted tar https://github.com/python/cpython/pull/2263 -Patch24: python3-sorted_tar.patch +# Fix SOURCE_DATE_EPOCH problems (bpo-34022, bpo-29708) +# https://github.com/python/cpython/pull/10775 +# https://github.com/python/cpython/pull/10327 +Patch24: bpo34022-stop_hash-based_invalidation_w_SOURCE_DATE_EPOCH.patch +Patch25: python3-imp-returntype.patch +# https://github.com/python/cpython/pull/7778 +Patch26: raise_SIGING_not_handled.patch +# Fix installation in /usr/local (boo#1071941), originally from Fedora +# https://src.fedoraproject.org/rpms/python3/blob/master/f/00251-change-user-install-location.patch +# Set values of prefix and exec_prefix in distutils install command +# to /usr/local if executable is /usr/bin/python* and RPM build +# is not detected to make pip and distutils install into separate location +Patch27: boo1071941-make-install-in-sep-loc.patch ### COMMON-PATCH-END ### %description @@ -240,20 +250,19 @@ %setup -q -n %{tarname} ### COMMON-PREP-BEGIN ### -%patch01 -p1 %patch02 -p1 %patch04 %patch06 -p1 -%patch07 %patch09 -p1 -%patch12 -p1 +# %%patch12 -p1 %patch15 -p1 -%patch21 -p1 -%patch22 -p1 %ifarch ppc ppc64 ppc64le %patch23 -p1 %endif %patch24 -p1 +%patch25 -p1 +%patch26 -p1 +%patch27 -p1 # drop Autoconf version requirement sed -i 's/^AC_PREREQ/dnl AC_PREREQ/' configure.ac @@ -261,7 +270,7 @@ # fix shebangs - convert /usr/local/bin/python and /usr/bin/env/python to /usr/bin/python3 for dir in Lib Tools; do # find *.py, filter to files that contain bad shebangs - # break up "/""usr" like this to prevent replacing with %{_prefix} + # break up "/""usr" like this to prevent replacing with %%{_prefix} find $dir -name '*.py' -type f -print0 \ | xargs -0 grep -lE '^#! *(/''usr/.*bin/(env +)?)?python' \ | xargs sed -r -i -e '1s@^#![[:space:]]*(/''usr/(local/)?bin/(env +)?)?python([0-9]+(\.[0-9]+)?)?@#!%{_bindir}/python3@' @@ -279,7 +288,7 @@ %build ### COMMON-CONFIG-BEGIN ### # use rpm_opt_flags -export OPT="%{optflags} -DOPENSSL_LOAD_CONF $(pkg-config --cflags-only-I libffi)" +export OPT="%{optflags} -DOPENSSL_LOAD_CONF -fwrapv $(pkg-config --cflags-only-I libffi)" touch -r %{SOURCE0} Makefile.pre.in @@ -292,14 +301,23 @@ %configure \ --docdir=%{_docdir}/python \ --enable-ipv6 \ - --with-fpectl \ --enable-shared \ --with-ensurepip=no \ --with-system-ffi \ --with-system-expat \ +%if 0%{?sle_version} >= 150000 && 0%{?is_opensuse} --with-lto \ +%endif +%if %{with profileopt} + --enable-optimizations \ +%endif --enable-loadable-sqlite-extensions +%ifarch aarch64 +# Builds fail on aarch64 because test_threading locks up +export PROFILE_TASK="-m test.regrtest --pgo -x test_threading" +%endif + # prevent make from trying to rebuild PYTHON_FOR_GEN stuff make -t Python/Python-ast.c \ Include/Python-ast.h \ @@ -378,8 +396,8 @@ ) # RPM macros -mkdir -p %{buildroot}%{_sysconfdir}/rpm -install -m 644 %{SOURCE8} %{buildroot}%{_sysconfdir}/rpm # macros.python3 +mkdir -p %{buildroot}%{_rpmconfigdir}/macros.d/ +install -m 644 %{SOURCE8} %{buildroot}%{_rpmconfigdir}/macros.d/ # macros.python3 # import_failed hooks FAILDIR=%{buildroot}/%{sitedir}/_import_failed @@ -474,7 +492,8 @@ # license text, not a doc because the code can use it at run-time %{sitedir}/LICENSE.txt # RPM macros -%{_sysconfdir}/rpm/macros.python3 +%{_rpmconfigdir}/macros.d/macros.python3 + # binary parts %dir %{sitedir}/lib-dynload %{dynlib array} @@ -490,6 +509,7 @@ %{dynlib _codecs_jp} %{dynlib _codecs_kr} %{dynlib _codecs_tw} +%{dynlib _contextvars} %{dynlib _crypt} %{dynlib _csv} %{dynlib _ctypes} @@ -507,13 +527,16 @@ %{dynlib mmap} %{dynlib _multibytecodec} %{dynlib _multiprocessing} +%if 0%{?suse_version} < 1500 %{dynlib nis} +%endif %{dynlib ossaudiodev} %{dynlib _opcode} %{dynlib parser} %{dynlib _pickle} %{dynlib _posixsubprocess} %{dynlib pyexpat} +%{dynlib _queue} %{dynlib _random} %{dynlib resource} %{dynlib select} @@ -524,6 +547,8 @@ %{dynlib syslog} %{dynlib termios} %{dynlib unicodedata} +%{dynlib _uuid} +%{dynlib _xxtestfuzz} %{dynlib zlib} # hashlib fallback modules %{dynlib _blake2} ++++++ python3-doc.spec ++++++ --- /var/tmp/diff_new_pack.6ULy7L/_old 2019-01-28 20:45:30.950090091 +0100 +++ /var/tmp/diff_new_pack.6ULy7L/_new 2019-01-28 20:45:30.954090087 +0100 @@ -1,7 +1,7 @@ # # spec file for package python3-doc # -# Copyright (c) 2018 SUSE LINUX GmbH, Nuernberg, Germany. +# Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany. # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -12,7 +12,7 @@ # license that conforms to the Open Source Definition (Version 1.9) # published by the Open Source Initiative. -# Please submit bugfixes or comments via http://bugs.opensuse.org/ +# Please submit bugfixes or comments via https://bugs.opensuse.org/ # @@ -21,9 +21,9 @@ %define tarname Python-%{tarversion} # the versions are autogenerated from pre_checkin.sh # based on the current source tarball -%define python_version 3.6 -%define python_version_abitag 36 -%define python_version_soname 3_6 +%define python_version 3.7 +%define python_version_abitag 37 +%define python_version_soname 3_7 %define sitedir %{_libdir}/python%{python_version} # three possible ABI kinds: m - pymalloc, d - debug build; see PEP 3149 %define abi_kind m @@ -52,7 +52,7 @@ ### COMMON-DEF-END ### # Name: python3-doc -Version: 3.6.5 +Version: 3.7.2 Release: 0 Summary: Additional Package Documentation for Python 3 License: Python-2.0 @@ -60,36 +60,41 @@ URL: http://www.python.org/ Source0: http://www.python.org/ftp/python/%{tarversion}/%{tarname}.tar.xz BuildRequires: libqt5-qttools -BuildRequires: python-Sphinx >= 1.2 +BuildRequires: python3-Sphinx >= 1.2 BuildRequires: xz Enhances: python3 = %{python_version} BuildArch: noarch # for consistency: ### COMMON-PATCH-BEGIN ### -# implement "--record-rpm" option for distutils installations -Patch01: Python-3.0b1-record-rpm.patch # support lib-vs-lib64 distinction -Patch02: python-3.6.0-multilib-new.patch +# New version from https://bugs.python.org/issue34032 +# Patch02: python-3.6.0-multilib-new.patch +# Unfortunately, the new version is still broken, so we have to use the +# old one +Patch02: python-3.6.0-multilib.patch # support finding packages in /usr/local, install to /usr/local by default Patch04: python-3.3.0b1-localpath.patch # replace DATE, TIME and COMPILER by fixed definitions to aid reproducible builds Patch06: python-3.3.0b1-fix_date_time_compiler.patch -# fix wrong include path in curses-panel module -Patch07: python-3.3.0b1-curses-panel.patch # POSIX_FADV_WILLNEED throws EINVAL. Use a different constant in test Patch09: python-3.3.0b1-test-posix_fadvise.patch -# Disable global and distutils sysconfig comparison test, we deviate from the default depending on optflags -Patch12: python-3.3.3-skip-distutils-test_sysconfig_module.patch # Raise timeout value for test_subprocess Patch15: subprocess-raise-timeout.patch -# PATCH-FIX-UPSTREAM [email protected] -- https://github.com/python/cpython/pull/296 -Patch21: 0001-allow-for-reproducible-builds-of-python-packages.patch -# PATCH-FEATURE-OPENSUSE order files for compilation until the underlying cause of bsc#1049186 is resolved -Patch22: distutils-reproducible-compile.patch # skip some tests only for PowerPC Patch23: skip_random_failing_tests.patch -# PATCH-FIX-UPSTREAM sorted tar https://github.com/python/cpython/pull/2263 -Patch24: python3-sorted_tar.patch +# Fix SOURCE_DATE_EPOCH problems (bpo-34022, bpo-29708) +# https://github.com/python/cpython/pull/10775 +# https://github.com/python/cpython/pull/10327 +Patch24: bpo34022-stop_hash-based_invalidation_w_SOURCE_DATE_EPOCH.patch +Patch25: python3-imp-returntype.patch +# https://github.com/python/cpython/pull/7778 +Patch26: raise_SIGING_not_handled.patch +# Fix installation in /usr/local (boo#1071941), originally from Fedora +# https://src.fedoraproject.org/rpms/python3/blob/master/f/00251-change-user-install-location.patch +# Set values of prefix and exec_prefix in distutils install command +# to /usr/local if executable is /usr/bin/python* and RPM build +# is not detected to make pip and distutils install into separate location +Patch27: boo1071941-make-install-in-sep-loc.patch ### COMMON-PATCH-END ### %description @@ -97,25 +102,47 @@ Extending and Embedding Reference, Python/C API Reference, Documenting Python, and Macintosh Module Reference in HTML format. +%package devhelp +Summary: Additional Package Documentation for Python 3 in devhelp format +Group: Documentation/Other + +%description devhelp +Tutorial, Global Module Index, Language Reference, Library Reference, +Extending and Embedding Reference, Python/C API Reference, Documenting +Python, and Macintosh Module Reference in format for devhelp. + + +%package qthelp +Summary: Additional Package Documentation for Python 3 in QtHelp format +Group: Documentation/Other + +%description qthelp +Tutorial, Global Module Index, Language Reference, Library Reference, +Extending and Embedding Reference, Python/C API Reference, Documenting +Python, and Macintosh Module Reference. + +This package allows use of the Python3 documentation in QtAssistant or +KDevelop. + + %prep %setup -q -n %{tarname} # for consistency ### COMMON-PREP-BEGIN ### -%patch01 -p1 %patch02 -p1 %patch04 %patch06 -p1 -%patch07 %patch09 -p1 -%patch12 -p1 +# %%patch12 -p1 %patch15 -p1 -%patch21 -p1 -%patch22 -p1 %ifarch ppc ppc64 ppc64le %patch23 -p1 %endif %patch24 -p1 +%patch25 -p1 +%patch26 -p1 +%patch27 -p1 # drop Autoconf version requirement sed -i 's/^AC_PREREQ/dnl AC_PREREQ/' configure.ac @@ -123,7 +150,7 @@ # fix shebangs - convert /usr/local/bin/python and /usr/bin/env/python to /usr/bin/python3 for dir in Lib Tools; do # find *.py, filter to files that contain bad shebangs - # break up "/""usr" like this to prevent replacing with %{_prefix} + # break up "/""usr" like this to prevent replacing with %%{_prefix} find $dir -name '*.py' -type f -print0 \ | xargs -0 grep -lE '^#! *(/''usr/.*bin/(env +)?)?python' \ | xargs sed -r -i -e '1s@^#![[:space:]]*(/''usr/(local/)?bin/(env +)?)?python([0-9]+(\.[0-9]+)?)?@#!%{_bindir}/python3@' @@ -145,6 +172,9 @@ cd Doc sed -i "s/^today = .*/today = '$TODAY_DATE'/" conf.py make -j1 html +# Build also devhelp files +sphinx-build -a -b devhelp . build/devhelp + # create a .qch file that can be used in QtAssistant or KDevelop sphinx-build -a -b qthelp . build/qthelp qhelpgenerator-qt5 build/qthelp/Python.qhp -o build/qthelp/Python.qch @@ -153,7 +183,7 @@ export PDOCS=%{buildroot}%{_docdir}/python3 mkdir -p $PDOCS # generated docs -rm Doc/build/html/.buildinfo +rm Doc/build/*/.buildinfo cp -r Doc/build/html $PDOCS install -m 644 Doc/build/qthelp/Python.qch $PDOCS # misc @@ -162,12 +192,22 @@ for i in Misc/* ; do [ -f $i ] && install -c -m 644 $i $PDOCS/Misc/ done +# devhelp +mkdir -p %{buildroot}%{_datadir}/gtk-doc/html/python3 +cp -r Doc/build/devhelp %{buildroot}%{_datadir}/gtk-doc/html/Python %files %defattr(644, root, root, 755) %dir %{_docdir}/python3 %doc %{_docdir}/python3/Misc %doc %{_docdir}/python3/html + +%files devhelp +%dir %{_datadir}/gtk-doc +%dir %{_datadir}/gtk-doc/html +%doc %{_datadir}/gtk-doc/html/Python + +%files qthelp %doc %{_docdir}/python3/Python.qch %changelog ++++++ python3.spec ++++++ --- /var/tmp/diff_new_pack.6ULy7L/_old 2019-01-28 20:45:30.982090058 +0100 +++ /var/tmp/diff_new_pack.6ULy7L/_new 2019-01-28 20:45:30.998090041 +0100 @@ -1,7 +1,7 @@ # # spec file for package python3 # -# Copyright (c) 2018 SUSE LINUX GmbH, Nuernberg, Germany. +# Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany. # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -12,7 +12,7 @@ # license that conforms to the Open Source Definition (Version 1.9) # published by the Open Source Initiative. -# Please submit bugfixes or comments via http://bugs.opensuse.org/ +# Please submit bugfixes or comments via https://bugs.opensuse.org/ # @@ -26,9 +26,9 @@ %define tarname Python-%{tarversion} # the versions are autogenerated from pre_checkin.sh # based on the current source tarball -%define python_version 3.6 -%define python_version_abitag 36 -%define python_version_soname 3_6 +%define python_version 3.7 +%define python_version_abitag 37 +%define python_version_soname 3_7 %define sitedir %{_libdir}/python%{python_version} # three possible ABI kinds: m - pymalloc, d - debug build; see PEP 3149 %define abi_kind m @@ -57,7 +57,7 @@ ### COMMON-DEF-END ### # Name: python3 -Version: 3.6.5 +Version: 3.7.2 Release: 0 Summary: Python 3 Interpreter License: Python-2.0 @@ -69,13 +69,19 @@ BuildRequires: fdupes BuildRequires: gcc-c++ BuildRequires: gdbm-devel -BuildRequires: gettext-tools +# Not using gettext-tools to avoid pulling glib2 dependencies to the chain +BuildRequires: gettext-runtime-mini BuildRequires: gmp-devel BuildRequires: intltool BuildRequires: libbz2-devel BuildRequires: libexpat-devel BuildRequires: libffi-devel -BuildRequires: libnsl-devel +# Installed libnsl-devel leads to build failures on nismodule.o +# https://bugs.python.org/issue32007 +# %%if 0%%{?sle_version} >= 1500 && 0%%{?is_opensuse} +# BuildRequires: libnsl-devel +# %%endif +BuildRequires: bluez-devel BuildRequires: lzma-devel BuildRequires: ncurses-devel BuildRequires: netcfg @@ -98,30 +104,35 @@ # see PACKAGING-NOTES for details # ### COMMON-PATCH-BEGIN ### -# implement "--record-rpm" option for distutils installations -Patch01: Python-3.0b1-record-rpm.patch # support lib-vs-lib64 distinction -Patch02: python-3.6.0-multilib-new.patch +# New version from https://bugs.python.org/issue34032 +# Patch02: python-3.6.0-multilib-new.patch +# Unfortunately, the new version is still broken, so we have to use the +# old one +Patch02: python-3.6.0-multilib.patch # support finding packages in /usr/local, install to /usr/local by default Patch04: python-3.3.0b1-localpath.patch # replace DATE, TIME and COMPILER by fixed definitions to aid reproducible builds Patch06: python-3.3.0b1-fix_date_time_compiler.patch -# fix wrong include path in curses-panel module -Patch07: python-3.3.0b1-curses-panel.patch # POSIX_FADV_WILLNEED throws EINVAL. Use a different constant in test Patch09: python-3.3.0b1-test-posix_fadvise.patch -# Disable global and distutils sysconfig comparison test, we deviate from the default depending on optflags -Patch12: python-3.3.3-skip-distutils-test_sysconfig_module.patch # Raise timeout value for test_subprocess Patch15: subprocess-raise-timeout.patch -# PATCH-FIX-UPSTREAM [email protected] -- https://github.com/python/cpython/pull/296 -Patch21: 0001-allow-for-reproducible-builds-of-python-packages.patch -# PATCH-FEATURE-OPENSUSE order files for compilation until the underlying cause of bsc#1049186 is resolved -Patch22: distutils-reproducible-compile.patch # skip some tests only for PowerPC Patch23: skip_random_failing_tests.patch -# PATCH-FIX-UPSTREAM sorted tar https://github.com/python/cpython/pull/2263 -Patch24: python3-sorted_tar.patch +# Fix SOURCE_DATE_EPOCH problems (bpo-34022, bpo-29708) +# https://github.com/python/cpython/pull/10775 +# https://github.com/python/cpython/pull/10327 +Patch24: bpo34022-stop_hash-based_invalidation_w_SOURCE_DATE_EPOCH.patch +Patch25: python3-imp-returntype.patch +# https://github.com/python/cpython/pull/7778 +Patch26: raise_SIGING_not_handled.patch +# Fix installation in /usr/local (boo#1071941), originally from Fedora +# https://src.fedoraproject.org/rpms/python3/blob/master/f/00251-change-user-install-location.patch +# Set values of prefix and exec_prefix in distutils install command +# to /usr/local if executable is /usr/bin/python* and RPM build +# is not detected to make pip and distutils install into separate location +Patch27: boo1071941-make-install-in-sep-loc.patch ### COMMON-PATCH-END ### %description @@ -139,7 +150,7 @@ development environment (python3-idle). %package tk -Summary: TkInter - Python Tk Interface +Summary: TkInter, a Python Tk Interface Group: Development/Libraries/Python Requires: %{name} = %{version} @@ -168,20 +179,19 @@ %prep %setup -q -n %{tarname} ### COMMON-PREP-BEGIN ### -%patch01 -p1 %patch02 -p1 %patch04 %patch06 -p1 -%patch07 %patch09 -p1 -%patch12 -p1 +# %%patch12 -p1 %patch15 -p1 -%patch21 -p1 -%patch22 -p1 %ifarch ppc ppc64 ppc64le %patch23 -p1 %endif %patch24 -p1 +%patch25 -p1 +%patch26 -p1 +%patch27 -p1 # drop Autoconf version requirement sed -i 's/^AC_PREREQ/dnl AC_PREREQ/' configure.ac @@ -189,7 +199,7 @@ # fix shebangs - convert /usr/local/bin/python and /usr/bin/env/python to /usr/bin/python3 for dir in Lib Tools; do # find *.py, filter to files that contain bad shebangs - # break up "/""usr" like this to prevent replacing with %{_prefix} + # break up "/""usr" like this to prevent replacing with %%{_prefix} find $dir -name '*.py' -type f -print0 \ | xargs -0 grep -lE '^#! *(/''usr/.*bin/(env +)?)?python' \ | xargs sed -r -i -e '1s@^#![[:space:]]*(/''usr/(local/)?bin/(env +)?)?python([0-9]+(\.[0-9]+)?)?@#!%{_bindir}/python3@' @@ -207,7 +217,7 @@ %build ### COMMON-CONFIG-BEGIN ### # use rpm_opt_flags -export OPT="%{optflags} -DOPENSSL_LOAD_CONF $(pkg-config --cflags-only-I libffi)" +export OPT="%{optflags} -DOPENSSL_LOAD_CONF -fwrapv $(pkg-config --cflags-only-I libffi)" touch -r %{SOURCE0} Makefile.pre.in @@ -220,14 +230,23 @@ %configure \ --docdir=%{_docdir}/python \ --enable-ipv6 \ - --with-fpectl \ --enable-shared \ --with-ensurepip=no \ --with-system-ffi \ --with-system-expat \ +%if 0%{?sle_version} >= 150000 && 0%{?is_opensuse} --with-lto \ +%endif +%if %{with profileopt} + --enable-optimizations \ +%endif --enable-loadable-sqlite-extensions +%ifarch aarch64 +# Builds fail on aarch64 because test_threading locks up +export PROFILE_TASK="-m test.regrtest --pgo -x test_threading" +%endif + # prevent make from trying to rebuild PYTHON_FOR_GEN stuff make -t Python/Python-ast.c \ Include/Python-ast.h \ @@ -246,7 +265,7 @@ # we patch out the message to recommend zypper in and thus this would fail EXCLUDE="$EXCLUDE test_pydoc" -%ifarch %{arm} +%ifarch %{arm} s390x # test_multiprocessing_forkserver is racy EXCLUDE="$EXCLUDE test_multiprocessing_forkserver" %endif @@ -266,12 +285,18 @@ # done have any such interface breaking the uuid module. EXCLUDE="$EXCLUDE test_uuid" +# # https://bugs.python.org/issue34022 +# # There seems to be troubles with the following tests when reproducible +# # build (with SOURCE_DATE_EPOCH environmental variable set) is run +EXCLUDE="$EXCLUDE test_cmd_line_script test_multiprocessing_main_handling test_runpy" + # Limit virtual memory to avoid spurious failures if test $(ulimit -v) = unlimited || test $(ulimit -v) -gt 10000000; then ulimit -v 10000000 || : fi -make -j1 test TESTOPTS="-u curses -x $EXCLUDE" +export PYTHONPATH="$(pwd -P)/Lib" +make -j1 test TESTOPTS="-u curses -v -x $EXCLUDE" # use network, be verbose: #make test TESTOPTS="-l -u network -v" @@ -303,13 +328,13 @@ done for library in \ - array _asyncio audioop binascii _bisect _bz2 cmath _codecs_* _crypt _csv \ - _ctypes _datetime _decimal fcntl grp _hashlib _heapq _json _lsprof \ - _lzma math mmap _multibytecodec _multiprocessing nis _opcode ossaudiodev \ - parser _pickle _posixsubprocess _random resource select _ssl _socket spwd \ - _struct syslog termios _testbuffer _testimportmultiple _testmultiphase \ - unicodedata zlib _ctypes_test _testcapi xxlimited \ - _elementtree pyexpat \ + array _asyncio audioop binascii _bisect _bz2 cmath _codecs_* \ + _contextvars _crypt _csv _ctypes _datetime _decimal fcntl grp \ + _hashlib _heapq _json _lsprof _lzma math mmap _multibytecodec \ + _multiprocessing _opcode ossaudiodev parser _pickle _posixsubprocess \ + _queue _random resource select _ssl _socket spwd _struct syslog termios \ + _testbuffer _testimportmultiple _testmultiphase unicodedata zlib \ + _ctypes_test _testcapi xxlimited _xxtestfuzz _elementtree pyexpat \ _md5 _sha1 _sha256 _sha512 _blake2 _sha3 do eval rm "%{buildroot}%{sitedir}/lib-dynload/$library.*" @@ -341,6 +366,9 @@ %dir %{sitedir}/lib-dynload %{sitedir}/sqlite3 %exclude %{sitedir}/sqlite3/test +%if 0%{?suse_version} < 1500 +%{dynlib nis} +%endif %{dynlib readline} %{dynlib _sqlite3} ++++++ Python-3.6.5.tar.xz -> Python-3.7.2.tar.xz ++++++ /work/SRC/openSUSE:Factory/python3/Python-3.6.5.tar.xz /work/SRC/openSUSE:Factory/.python3.new.28833/Python-3.7.2.tar.xz differ: char 26, line 1 ++++++ baselibs.conf ++++++ --- /var/tmp/diff_new_pack.6ULy7L/_old 2019-01-28 20:45:31.126089906 +0100 +++ /var/tmp/diff_new_pack.6ULy7L/_new 2019-01-28 20:45:31.130089902 +0100 @@ -1,3 +1,3 @@ python3 python3-base -libpython3_6m1_0 +libpython3_7m1_0 ++++++ boo1071941-make-install-in-sep-loc.patch ++++++ >From 332b947dfc8d0f0d3a4525864b121d0f239beb4d Mon Sep 17 00:00:00 2001 From: Michal Cyprian <[email protected]> Date: Jun 26 2017 14:32:56 +0000 Subject: Make pip and distutils in user environment install into separate location --- --- /dev/null +++ b/00251-change-user-install-location.patch @@ -0,0 +1,46 @@ +diff --git a/Lib/distutils/command/install.py b/Lib/distutils/command/install.py +index 9d31d13..ed44a93 100644 +--- a/Lib/distutils/command/install.py ++++ b/Lib/distutils/command/install.py +@@ -424,8 +424,18 @@ class install(Command): + raise DistutilsOptionError( + "must not supply exec-prefix without prefix") + +- self.prefix = os.path.normpath(sys.prefix) +- self.exec_prefix = os.path.normpath(sys.exec_prefix) ++ # self.prefix is set to sys.prefix + /local/ ++ # if the executable is /usr/bin/python* and RPM build ++ # is not detected to make pip and distutils install into ++ # the separate location. ++ if (sys.executable.startswith("/usr/bin/python") ++ and 'RPM_BUILD_ROOT' not in os.environ): ++ addition = "/local" ++ else: ++ addition = "" ++ ++ self.prefix = os.path.normpath(sys.prefix) + addition ++ self.exec_prefix = os.path.normpath(sys.exec_prefix) + addition + + else: + if self.exec_prefix is None: +diff --git a/Lib/site.py b/Lib/site.py +index 4744eb0..b5fe571 100644 +--- a/Lib/site.py ++++ b/Lib/site.py +@@ -326,7 +326,15 @@ def getsitepackages(prefixes=None): + return sitepackages + + def addsitepackages(known_paths, prefixes=None): +- """Add site-packages to sys.path""" ++ """Add site-packages to sys.path. ++ ++ '/usr/local' is included in PREFIXES if the executable is /usr/bin/python* ++ and RPM build is not detected to make sudo pip installed packages visible. ++ ++ """ ++ if (ENABLE_USER_SITE and sys.executable.startswith("/usr/bin/python") ++ and 'RPM_BUILD_ROOT' not in os.environ): ++ PREFIXES.insert(0, "/usr/local") + for sitedir in getsitepackages(prefixes): + if os.path.isdir(sitedir): + addsitedir(sitedir, known_paths) ++++++ bpo34022-stop_hash-based_invalidation_w_SOURCE_DATE_EPOCH.patch ++++++ >From 2c096b513273a758b446405d9e5efe4860af1036 Mon Sep 17 00:00:00 2001 From: Elvis Pranskevichus <[email protected]> Date: Thu, 27 Sep 2018 13:05:14 -0400 Subject: [PATCH] bpo-34022: Stop forcing of hash-based invalidation with SOURCE_DATE_EPOCH Unconditional forcing of ``CHECKED_HASH`` invalidation was introduced in 3.7.0 in bpo-29708. The change is bad, as it unconditionally overrides *invalidation_mode*, even if it was passed as an explicit argument to ``py_compile.compile()`` or ``compileall``. An environment variable should *never* override an explicit argument to a library function. That change leads to multiple test failures if the ``SOURCE_DATE_EPOCH`` environment variable is set. This changes ``py_compile.compile()`` to only look at ``SOURCE_DATE_EPOCH`` if no explicit *invalidation_mode* was specified. I also made various relevant tests run with explicit control over the value of ``SOURCE_DATE_EPOCH``. While looking at this, I noticed that ``zipimport`` does not work with hash-based .pycs _at all_, though I left the fixes for subsequent commits. --- Doc/library/compileall.rst | 11 ++-- Doc/library/py_compile.rst | 13 ++-- Lib/compileall.py | 20 ++++-- Lib/py_compile.py | 13 +++- Lib/test/test_compileall.py | 50 ++++++++++++-- .../test_importlib/source/test_file_loader.py | 15 +++++ Lib/test/test_py_compile.py | 66 +++++++++++++++++-- .../2018-09-27-13-14-15.bpo-34022.E2cl0r.rst | 3 + 8 files changed, 161 insertions(+), 30 deletions(-) create mode 100644 Misc/NEWS.d/next/Library/2018-09-27-13-14-15.bpo-34022.E2cl0r.rst --- a/Doc/library/py_compile.rst +++ b/Doc/library/py_compile.rst @@ -82,6 +82,11 @@ byte-code cache files in the directory c overrides the value of the *invalidation_mode* argument, and determines its default value instead. + .. versionchanged:: 3.7.2 + The :envvar:`SOURCE_DATE_EPOCH` environment variable no longer + overrides the value of the *invalidation_mode* argument, and determines + its default value instead. + .. class:: PycInvalidationMode --- a/Lib/test/test_compileall.py +++ b/Lib/test/test_compileall.py @@ -210,6 +210,21 @@ class CompileallTestsWithoutSourceEpoch( pass + +class CompileallTestsWithSourceEpoch(CompileallTestsBase, + unittest.TestCase, + metaclass=SourceDateEpochTestMeta, + source_date_epoch=True): + pass + + +class CompileallTestsWithoutSourceEpoch(CompileallTestsBase, + unittest.TestCase, + metaclass=SourceDateEpochTestMeta, + source_date_epoch=False): + pass + + class EncodingTest(unittest.TestCase): """Issue 6716: compileall should escape source code when printing errors to stdout.""" @@ -580,6 +595,21 @@ class CommandLineTestsBase: class CommmandLineTestsWithSourceEpoch(CommandLineTestsBase, + unittest.TestCase, + metaclass=SourceDateEpochTestMeta, + source_date_epoch=True): + pass + + +class CommmandLineTestsNoSourceEpoch(CommandLineTestsBase, + unittest.TestCase, + metaclass=SourceDateEpochTestMeta, + source_date_epoch=False): + pass + + + +class CommmandLineTestsWithSourceEpoch(CommandLineTestsBase, unittest.TestCase, metaclass=SourceDateEpochTestMeta, source_date_epoch=True): --- a/Lib/test/test_importlib/source/test_file_loader.py +++ b/Lib/test/test_importlib/source/test_file_loader.py @@ -22,6 +22,9 @@ from test.support import make_legacy_pyc from test.test_py_compile import without_source_date_epoch from test.test_py_compile import SourceDateEpochTestMeta +from test.test_py_compile import without_source_date_epoch +from test.test_py_compile import SourceDateEpochTestMeta + class SimpleTest(abc.LoaderTests): @@ -363,6 +366,17 @@ class SimpleTest(abc.LoaderTests): class SourceDateEpochTestMeta(SourceDateEpochTestMeta, + type(Source_SimpleTest)): + pass + + +class SourceDateEpoch_SimpleTest(Source_SimpleTest, + metaclass=SourceDateEpochTestMeta, + source_date_epoch=True): + pass + + +class SourceDateEpochTestMeta(SourceDateEpochTestMeta, type(Source_SimpleTest)): pass --- a/Lib/test/test_py_compile.py +++ b/Lib/test/test_py_compile.py @@ -207,5 +207,19 @@ class PyCompileTestsWithoutSourceEpoch(P pass +class PyCompileTestsWithSourceEpoch(PyCompileTestsBase, + unittest.TestCase, + metaclass=SourceDateEpochTestMeta, + source_date_epoch=True): + pass + + +class PyCompileTestsWithoutSourceEpoch(PyCompileTestsBase, + unittest.TestCase, + metaclass=SourceDateEpochTestMeta, + source_date_epoch=False): + pass + + if __name__ == "__main__": unittest.main() --- /dev/null +++ b/Misc/NEWS.d/next/Library/2018-09-27-13-14-15.bpo-34022.E2cl0r.rst @@ -0,0 +1,3 @@ +The :envvar:`SOURCE_DATE_EPOCH` environment variable no longer overrides the +value of the *invalidation_mode* argument to :func:`py_compile.compile`, and +determines its default value instead. ++++++ import_failed.map ++++++ --- /var/tmp/diff_new_pack.6ULy7L/_old 2019-01-28 20:45:31.158089873 +0100 +++ /var/tmp/diff_new_pack.6ULy7L/_new 2019-01-28 20:45:31.158089873 +0100 @@ -4,4 +4,4 @@ python3-tk: tkinter _tkinter python3-curses: curses _curses _curses_panel python3-dbm: dbm _dbm _gdbm -python3: sqlite3 readline _sqlite3 +python3: sqlite3 nis readline _sqlite3 ++++++ pre_checkin.sh ++++++ --- /var/tmp/diff_new_pack.6ULy7L/_old 2019-01-28 20:45:31.186089843 +0100 +++ /var/tmp/diff_new_pack.6ULy7L/_new 2019-01-28 20:45:31.190089839 +0100 @@ -129,3 +129,7 @@ # run test inclusion check python3 skipped_tests.py + +# I really don't to keep all three *.changes files separate +cp python3-base.changes python3.changes +cp python3-base.changes python3-doc.changes ++++++ python-3.3.0b1-fix_date_time_compiler.patch ++++++ --- /var/tmp/diff_new_pack.6ULy7L/_old 2019-01-28 20:45:31.198089830 +0100 +++ /var/tmp/diff_new_pack.6ULy7L/_new 2019-01-28 20:45:31.198089830 +0100 @@ -1,8 +1,6 @@ -Index: Python-3.6.1/Makefile.pre.in -=================================================================== ---- Python-3.6.1.orig/Makefile.pre.in -+++ Python-3.6.1/Makefile.pre.in -@@ -743,11 +743,18 @@ Modules/getbuildinfo.o: $(PARSER_OBJS) \ +--- a/Makefile.pre.in ++++ b/Makefile.pre.in +@@ -754,11 +754,18 @@ Modules/getbuildinfo.o: $(PARSER_OBJS) \ $(MODOBJS) \ $(srcdir)/Modules/getbuildinfo.c $(CC) -c $(PY_CORE_CFLAGS) \ ++++++ python-3.3.0b1-test-posix_fadvise.patch ++++++ --- /var/tmp/diff_new_pack.6ULy7L/_old 2019-01-28 20:45:31.210089818 +0100 +++ /var/tmp/diff_new_pack.6ULy7L/_new 2019-01-28 20:45:31.210089818 +0100 @@ -1,8 +1,6 @@ -Index: Python-3.3.0b1/Lib/test/test_posix.py -=================================================================== ---- Python-3.3.0b1.orig/Lib/test/test_posix.py 2012-06-26 22:19:48.000000000 +0200 -+++ Python-3.3.0b1/Lib/test/test_posix.py 2012-08-03 14:06:26.000000000 +0200 -@@ -231,7 +231,7 @@ +--- a/Lib/test/test_posix.py ++++ b/Lib/test/test_posix.py +@@ -409,7 +409,7 @@ class PosixTester(unittest.TestCase): def test_posix_fadvise(self): fd = os.open(support.TESTFN, os.O_RDONLY) try: ++++++ python-3.6.0-multilib-new.patch -> python-3.6.0-multilib.patch ++++++ --- /work/SRC/openSUSE:Factory/python3/python-3.6.0-multilib-new.patch 2018-04-05 15:30:04.943535645 +0200 +++ /work/SRC/openSUSE:Factory/.python3.new.28833/python-3.6.0-multilib.patch 2019-01-28 20:45:29.546091568 +0100 @@ -1,8 +1,6 @@ -Index: Python-3.6.5/configure.ac -=================================================================== ---- Python-3.6.5.orig/configure.ac -+++ Python-3.6.5/configure.ac -@@ -4662,12 +4662,26 @@ AC_MSG_CHECKING(LDVERSION) +--- a/configure.ac ++++ b/configure.ac +@@ -4733,12 +4733,26 @@ AC_MSG_CHECKING(LDVERSION) LDVERSION='$(VERSION)$(ABIFLAGS)' AC_MSG_RESULT($LDVERSION) @@ -31,11 +29,9 @@ fi AC_SUBST(LIBPL) -Index: Python-3.6.5/Makefile.pre.in -=================================================================== ---- Python-3.6.5.orig/Makefile.pre.in -+++ Python-3.6.5/Makefile.pre.in -@@ -127,13 +127,16 @@ exec_prefix= @exec_prefix@ +--- a/Makefile.pre.in ++++ b/Makefile.pre.in +@@ -129,13 +129,16 @@ exec_prefix= @exec_prefix@ # Install prefix for data files datarootdir= @datarootdir@ @@ -53,7 +49,7 @@ ABIFLAGS= @ABIFLAGS@ # Detailed destination directories -@@ -743,6 +746,7 @@ Modules/getpath.o: $(srcdir)/Modules/get +@@ -762,6 +765,7 @@ Modules/getpath.o: $(srcdir)/Modules/get -DEXEC_PREFIX='"$(exec_prefix)"' \ -DVERSION='"$(VERSION)"' \ -DVPATH='"$(VPATH)"' \ @@ -61,11 +57,9 @@ -o $@ $(srcdir)/Modules/getpath.c Programs/python.o: $(srcdir)/Programs/python.c -Index: Python-3.6.5/Modules/getpath.c -=================================================================== ---- Python-3.6.5.orig/Modules/getpath.c -+++ Python-3.6.5/Modules/getpath.c -@@ -51,9 +51,10 @@ +--- a/Modules/getpath.c ++++ b/Modules/getpath.c +@@ -52,9 +52,10 @@ * pybuilddir.txt. If the landmark is found, we're done. * * For the remaining steps, the prefix landmark will always be @@ -79,7 +73,7 @@ * build directory checking is performed; if the first step did not find * the landmarks, the assumption is that python is running from an * installed setup. -@@ -82,7 +83,7 @@ +@@ -83,7 +84,7 @@ * containing the shared library modules is appended. The environment * variable $PYTHONPATH is inserted in front of it all. Finally, the * prefix and exec_prefix globals are tweaked so they reflect the values @@ -88,7 +82,7 @@ * off. If either points to the build directory, the globals are reset to * the corresponding preprocessor variables (so sys.prefix will reflect the * installation location, even though sys.path points into the build -@@ -101,8 +102,8 @@ +@@ -102,8 +103,8 @@ extern "C" { #endif @@ -99,19 +93,17 @@ #endif #ifndef LANDMARK -@@ -494,7 +495,7 @@ calculate_path(void) - _pythonpath = Py_DecodeLocale(PYTHONPATH, NULL); - _prefix = Py_DecodeLocale(PREFIX, NULL); - _exec_prefix = Py_DecodeLocale(EXEC_PREFIX, NULL); -- lib_python = Py_DecodeLocale("lib/python" VERSION, NULL); -+ lib_python = Py_DecodeLocale(PLATLIBDIR "/python" VERSION, NULL); - - if (!_pythonpath || !_prefix || !_exec_prefix || !lib_python) { - Py_FatalError( -Index: Python-3.6.5/Lib/distutils/command/install.py -=================================================================== ---- Python-3.6.5.orig/Lib/distutils/command/install.py -+++ Python-3.6.5/Lib/distutils/command/install.py +@@ -867,7 +868,7 @@ calculate_init(PyCalculatePath *calculat + if (!calculate->prefix) { + return DECODE_LOCALE_ERR("EXEC_PREFIX define", len); + } +- calculate->lib_python = Py_DecodeLocale("lib/python" VERSION, &len); ++ calculate->lib_python = Py_DecodeLocale(PLATLIBDIR "/python" VERSION, &len); + if (!calculate->lib_python) { + return DECODE_LOCALE_ERR("EXEC_PREFIX define", len); + } +--- a/Lib/distutils/command/install.py ++++ b/Lib/distutils/command/install.py @@ -30,7 +30,7 @@ WINDOWS_SCHEME = { INSTALL_SCHEMES = { 'unix_prefix': { @@ -121,7 +113,7 @@ 'headers': '$base/include/python$py_version_short$abiflags/$dist_name', 'scripts': '$base/bin', 'data' : '$base', -@@ -284,7 +284,7 @@ class install(Command): +@@ -281,7 +281,7 @@ class install(Command): # about needing recursive variable expansion (shudder). py_version = sys.version.split()[0] @@ -130,7 +122,7 @@ try: abiflags = sys.abiflags except AttributeError: -@@ -301,6 +301,7 @@ class install(Command): +@@ -298,6 +298,7 @@ class install(Command): 'sys_exec_prefix': exec_prefix, 'exec_prefix': exec_prefix, 'abiflags': abiflags, @@ -138,10 +130,8 @@ } if HAS_USER_SITE: -Index: Python-3.6.5/Lib/distutils/sysconfig.py -=================================================================== ---- Python-3.6.5.orig/Lib/distutils/sysconfig.py -+++ Python-3.6.5/Lib/distutils/sysconfig.py +--- a/Lib/distutils/sysconfig.py ++++ b/Lib/distutils/sysconfig.py @@ -129,8 +129,9 @@ def get_python_lib(plat_specific=0, stan prefix = plat_specific and EXEC_PREFIX or PREFIX @@ -153,10 +143,8 @@ if standard_lib: return libpython else: -Index: Python-3.6.5/Lib/sysconfig.py -=================================================================== ---- Python-3.6.5.orig/Lib/sysconfig.py -+++ Python-3.6.5/Lib/sysconfig.py +--- a/Lib/sysconfig.py ++++ b/Lib/sysconfig.py @@ -20,10 +20,10 @@ __all__ = [ _INSTALL_SCHEMES = { @@ -171,11 +159,9 @@ 'include': '{installed_base}/include/python{py_version_short}{abiflags}', 'platinclude': -Index: Python-3.6.5/Lib/pydoc.py -=================================================================== ---- Python-3.6.5.orig/Lib/pydoc.py -+++ Python-3.6.5/Lib/pydoc.py -@@ -63,6 +63,7 @@ import pkgutil +--- a/Lib/pydoc.py ++++ b/Lib/pydoc.py +@@ -66,6 +66,7 @@ import pkgutil import platform import re import sys @@ -183,7 +169,7 @@ import time import tokenize import urllib.parse -@@ -395,9 +396,7 @@ class Doc: +@@ -398,9 +399,7 @@ class Doc: docmodule = docclass = docroutine = docother = docproperty = docdata = fail @@ -194,11 +180,9 @@ """Return the location of module docs or None""" try: -Index: Python-3.6.5/Lib/site.py -=================================================================== ---- Python-3.6.5.orig/Lib/site.py -+++ Python-3.6.5/Lib/site.py -@@ -304,9 +304,15 @@ def getsitepackages(prefixes=None): +--- a/Lib/site.py ++++ b/Lib/site.py +@@ -334,9 +334,15 @@ def getsitepackages(prefixes=None): seen.add(prefix) if os.sep == '/': @@ -215,10 +199,8 @@ else: sitepackages.append(prefix) sitepackages.append(os.path.join(prefix, "lib", "site-packages")) -Index: Python-3.6.5/Lib/trace.py -=================================================================== ---- Python-3.6.5.orig/Lib/trace.py -+++ Python-3.6.5/Lib/trace.py +--- a/Lib/trace.py ++++ b/Lib/trace.py @@ -53,6 +53,7 @@ import linecache import os import re @@ -227,7 +209,7 @@ import token import tokenize import inspect -@@ -677,9 +678,8 @@ def main(): +@@ -659,9 +660,8 @@ def main(): opts = parser.parse_args() if opts.ignore_dir: @@ -239,14 +221,12 @@ def parse_ignore_dir(s): s = os.path.expanduser(os.path.expandvars(s)) -Index: Python-3.6.5/Lib/test/test_site.py -=================================================================== ---- Python-3.6.5.orig/Lib/test/test_site.py -+++ Python-3.6.5/Lib/test/test_site.py -@@ -260,8 +260,9 @@ class HelperFunctionsTests(unittest.Test - self.assertEqual(dirs[1], wanted) - elif os.sep == '/': - # OS X non-framework builds, Linux, FreeBSD, etc +--- a/Lib/test/test_site.py ++++ b/Lib/test/test_site.py +@@ -267,8 +267,9 @@ class HelperFunctionsTests(unittest.Test + dirs = site.getsitepackages() + if os.sep == '/': + # OS X, Linux, FreeBSD, etc - self.assertEqual(len(dirs), 1) - wanted = os.path.join('xoxo', 'lib', + platlibdir = sysconfig.get_config_var('platlibdir') @@ -255,11 +235,9 @@ 'python%d.%d' % sys.version_info[:2], 'site-packages') self.assertEqual(dirs[0], wanted) -Index: Python-3.6.5/Lib/test/test_sysconfig.py -=================================================================== ---- Python-3.6.5.orig/Lib/test/test_sysconfig.py -+++ Python-3.6.5/Lib/test/test_sysconfig.py -@@ -266,6 +266,7 @@ class TestSysConfig(unittest.TestCase): +--- a/Lib/test/test_sysconfig.py ++++ b/Lib/test/test_sysconfig.py +@@ -271,6 +271,7 @@ class TestSysConfig(unittest.TestCase): # is similar to the global posix_prefix one base = get_config_var('base') user = get_config_var('userbase') @@ -267,7 +245,7 @@ # the global scheme mirrors the distinction between prefix and # exec-prefix but not the user scheme, so we have to adapt the paths # before comparing (issue #9100) -@@ -280,8 +281,19 @@ class TestSysConfig(unittest.TestCase): +@@ -285,8 +286,19 @@ class TestSysConfig(unittest.TestCase): # before comparing global_path = global_path.replace(sys.base_prefix, sys.prefix) base = base.replace(sys.base_prefix, sys.prefix) ++++++ python3-base-rpmlintrc ++++++ # RPM macros are not configuration: addFilter("non-conffile-in-etc.*/etc/rpm/macros.python3") # This file is required for testing addFilter("devel-file-in-non-devel-package.*/usr/lib.*/python3.*/distutils/tests/xxmodule.c") # Obviously, these files are meant to be empty: addFilter("zero-length.*/usr/lib.*/python3.*/test/nullcert.pem") addFilter("zero-length.*/usr/lib.*/python3.*/test/namespace_pkgs/module_and_namespace_package/a_test/empty") ++++++ python3-imp-returntype.patch ++++++ >From 7bd6f0e5500f778e940374237b94651f60ae1990 Mon Sep 17 00:00:00 2001 From: "Miss Islington (bot)" <[email protected]> Date: Fri, 6 Jul 2018 21:00:45 -0700 Subject: [PATCH] closes bpo-34056: Always return bytes from _HackedGetData.get_data(). (GH-8130) * Always return bytes from _HackedGetData.get_data(). Ensure the imp.load_source shim always returns bytes by reopening the file in binary mode if needed. Hash-based pycs have to receive the source code in bytes. It's tempting to change imp.get_suffixes() to always return 'rb' as a mode, but that breaks some stdlib tests and likely 3rdparty code, too. (cherry picked from commit b0274f2cddd36b49fe5080efbe160277ef546471) Co-authored-by: Benjamin Peterson <[email protected]> --- Lib/imp.py | 13 ++++++------- Lib/test/test_imp.py | 15 +++++++++++++++ .../2018-07-05-22-45-46.bpo-34056.86isrU.rst | 3 +++ 3 files changed, 24 insertions(+), 7 deletions(-) create mode 100644 Misc/NEWS.d/next/Library/2018-07-05-22-45-46.bpo-34056.86isrU.rst --- a/Lib/test/test_imp.py +++ b/Lib/test/test_imp.py @@ -365,6 +365,20 @@ class ImportTests(unittest.TestCase): mod = imp.load_module('mymod', file, path, description) self.assertEqual(mod.x, 42) + def test_find_and_load_checked_pyc(self): + # issue 34056 + with support.temp_cwd(): + with open('mymod.py', 'wb') as fp: + fp.write(b'x = 42\n') + py_compile.compile( + 'mymod.py', + doraise=True, + invalidation_mode=py_compile.PycInvalidationMode.CHECKED_HASH, + ) + file, path, description = imp.find_module('mymod', path=['.']) + mod = imp.load_module('mymod', file, path, description) + self.assertEqual(mod.x, 42) + class ReloadTests(unittest.TestCase): --- /dev/null +++ b/Misc/NEWS.d/next/Library/2018-07-05-22-45-46.bpo-34056.86isrU.rst @@ -0,0 +1,3 @@ +Ensure the loader shim created by ``imp.load_module`` always returns bytes +from its ``get_data()`` function. This fixes using ``imp.load_module`` with +:pep:`552` hash-based pycs. ++++++ raise_SIGING_not_handled.patch ++++++ >From 87b47458b2553b28fb35b5848c0c5efad8a54718 Mon Sep 17 00:00:00 2001 From: Victor Stinner <[email protected]> Date: Wed, 27 Jul 2016 11:06:43 +0200 Subject: [PATCH] Raise an exception if the SIGINT signal is ignored or not handled Original patch by @vstinner: Attached interrupt_main.patch fixes for ``_thread.interrupt_main()``. Raise an exception if the ``SIGINT`` signal is ignored (``SIG_IGN``) or not handled by Python (``SIG_DFL``). The patch updates the documentation and adds unit tests. Additional fixes by @mcepl: Add missing import signal Add forgotten change. It is not true, GIL must be hold for PyErr_SetString() function. Fix the Misc/ACKS with the proper spelling of my name. --- Doc/c-api/exceptions.rst | 22 ++++++---- Doc/library/_thread.rst | 11 ++++- Include/pyerrors.h | 1 + Lib/test/test_threading.py | 40 +++++++++++++++++++ Misc/ACKS | 2 +- .../2016-07-27-11-06-43.bpo-23395.MuCEX9.rst | 3 ++ Modules/_threadmodule.c | 4 +- Modules/signalmodule.c | 34 ++++++++++++++-- 8 files changed, 103 insertions(+), 14 deletions(-) create mode 100644 Misc/NEWS.d/next/Library/2016-07-27-11-06-43.bpo-23395.MuCEX9.rst --- a/Doc/c-api/exceptions.rst +++ b/Doc/c-api/exceptions.rst @@ -504,18 +504,26 @@ Signal Handling cleared if it was previously set. -.. c:function:: void PyErr_SetInterrupt() +.. c:function:: int PyErr_SetInterruptWithErr() .. index:: single: SIGINT - single: KeyboardInterrupt (built-in exception) - This function simulates the effect of a :const:`SIGINT` signal arriving --- the - next time :c:func:`PyErr_CheckSignals` is called, :exc:`KeyboardInterrupt` will - be raised. It may be called without holding the interpreter lock. + Simulate the effect of a :data:`signal.SIGINT` signal arriving. The next + time :c:func:`PyErr_CheckSignals` is called, the Python + :data:`signal.SIGINT` signal handler will be raised. + + The :data:`signal.SIGINT` signal must be handled by Python, otherwise an + exception is raised and return ``-1`` on error. Return ``0`` on success. + + The GIL doesn't need to be hold to call this function. + + .. versionadded:: 3.6 + + +.. c:function:: void PyErr_SetInterrupt() - .. % XXX This was described as obsolete, but is used in - .. % _thread.interrupt_main() (used from IDLE), so it's still needed. + Deprecated version :c:func:`PyErr_SetInterruptWithErr` which ignores errors. .. c:function:: int PySignal_SetWakeupFd(int fd) --- a/Doc/library/_thread.rst +++ b/Doc/library/_thread.rst @@ -53,8 +53,15 @@ This module defines the following consta .. function:: interrupt_main() - Raise a :exc:`KeyboardInterrupt` exception in the main thread. A subthread can - use this function to interrupt the main thread. + Simulate the effect of a :data:`signal.SIGINT` signal arriving in the main + thread. A thread can use this function to interrupt the main thread. + + The :data:`signal.SIGINT` signal must be handled by Python, otherwise + an exception is raised. + + .. versionchanged:: 3.6 + The function now raises an exception if the signal is ignored or not + handled by Python. .. function:: exit() --- a/Include/pyerrors.h +++ b/Include/pyerrors.h @@ -354,6 +354,7 @@ PyAPI_FUNC(PyObject *) _PyErr_TrySetFrom /* In signalmodule.c */ PyAPI_FUNC(int) PyErr_CheckSignals(void); PyAPI_FUNC(void) PyErr_SetInterrupt(void); +PyAPI_FUNC(int) PyErr_SetInterruptWithErr(void); /* In signalmodule.c */ #ifndef Py_LIMITED_API --- a/Lib/test/test_threading.py +++ b/Lib/test/test_threading.py @@ -16,6 +16,7 @@ import unittest import weakref import os import subprocess +import signal from test import lock_tests from test import support @@ -1164,6 +1165,7 @@ class BoundedSemaphoreTests(lock_tests.B class BarrierTests(lock_tests.BarrierTests): barriertype = staticmethod(threading.Barrier) + class MiscTestCase(unittest.TestCase): def test__all__(self): extra = {"ThreadError"} @@ -1171,5 +1173,43 @@ class MiscTestCase(unittest.TestCase): support.check__all__(self, threading, ('threading', '_thread'), extra=extra, blacklist=blacklist) + +class InterruptMainTests(unittest.TestCase): + def test_interrupt_main_subthread(self): + #Calling start_new_thread with a function that executes interrupt_main + # should raise KeyboardInterrupt upon completion. + def call_interrupt(): + _thread.interrupt_main() + t = threading.Thread(target=call_interrupt) + with self.assertRaises(KeyboardInterrupt): + t.start() + t.join() + t.join() + + def test_interrupt_main_mainthread(self): + # Make sure that if interrupt_main is called in main threat that + # KeyboardInterrupt is raised instantly. + with self.assertRaises(KeyboardInterrupt): + _thread.interrupt_main() + + def test_interrupt_main_error(self): + handler = signal.getsignal(signal.SIGINT) + try: + signal.signal(signal.SIGINT, signal.SIG_IGN) + with self.assertRaises(RuntimeError) as cm: + _thread.interrupt_main() + self.assertEqual(str(cm.exception), + 'the SIGINT signal is ignored') + + signal.signal(signal.SIGINT, signal.SIG_DFL) + with self.assertRaises(RuntimeError) as cm: + _thread.interrupt_main() + self.assertEqual(str(cm.exception), + 'the SIGINT signal is not handled by Python') + + finally: + signal.signal(signal.SIGINT, handler) + + if __name__ == "__main__": unittest.main() --- a/Misc/ACKS +++ b/Misc/ACKS @@ -254,7 +254,7 @@ Donn Cave Charles Cazabon Jesús Cea Avión Per Cederqvist -Matej Cepl +Matěj Cepl Carl Cerecke Octavian Cerna Michael Cetrulo --- /dev/null +++ b/Misc/NEWS.d/next/Library/2016-07-27-11-06-43.bpo-23395.MuCEX9.rst @@ -0,0 +1,3 @@ +``_thread.interrupt_main()`` now raises an exception if the +``SIGINT`` signal is ignored or not handled by Python. +Patch by Viktor Stinner --- a/Modules/_threadmodule.c +++ b/Modules/_threadmodule.c @@ -1105,7 +1105,9 @@ thread to exit silently unless the excep static PyObject * thread_PyThread_interrupt_main(PyObject * self) { - PyErr_SetInterrupt(); + if (PyErr_SetInterruptWithErr() < 0) { + return NULL; + } Py_RETURN_NONE; } --- a/Modules/signalmodule.c +++ b/Modules/signalmodule.c @@ -1562,9 +1562,37 @@ PyErr_CheckSignals(void) } -/* Replacements for intrcheck.c functionality - * Declared in pyerrors.h - */ +/* Simulate the effect of a SIGINT signal arriving. The next time + PyErr_CheckSignals() is called, the Python SIGINT signal handler will be + raised. + + The SIGINT signal must be handled by Python, otherwise an exception is + raised and return -1. Return 0 on success. */ +int +PyErr_SetInterruptWithErr(void) +{ + if (Handlers[SIGINT].func == IgnoreHandler) { + PyErr_SetString(PyExc_RuntimeError, + "the SIGINT signal is ignored"); + return -1; + } + + if (Handlers[SIGINT].func == DefaultHandler) { + PyErr_SetString(PyExc_RuntimeError, + "the SIGINT signal is not handled by Python"); + return -1; + } + + trip_signal(SIGINT); + return 0; +} + + +/* Simulate the effect of a SIGINT signal arriving. The next time + PyErr_CheckSignals() is called, the Python SIGINT signal handler will be + raised. + + The GIL doesn't need to be hold to call this function. */ void PyErr_SetInterrupt(void) { ++++++ skip_random_failing_tests.patch ++++++ --- /var/tmp/diff_new_pack.6ULy7L/_old 2019-01-28 20:45:31.274089751 +0100 +++ /var/tmp/diff_new_pack.6ULy7L/_new 2019-01-28 20:45:31.274089751 +0100 @@ -80,11 +80,9 @@ Lib/test/test_asyncio/test_events.py | 4 +++- 2 files changed, 6 insertions(+), 1 deletion(-) -Index: Python-3.6.4/Lib/test/_test_multiprocessing.py -=================================================================== ---- Python-3.6.4.orig/Lib/test/_test_multiprocessing.py -+++ Python-3.6.4/Lib/test/_test_multiprocessing.py -@@ -1145,6 +1145,7 @@ class _TestCondition(BaseTestCase): +--- a/Lib/test/_test_multiprocessing.py ++++ b/Lib/test/_test_multiprocessing.py +@@ -1437,6 +1437,7 @@ class _TestCondition(BaseTestCase): success.value = True @unittest.skipUnless(HAS_SHAREDCTYPES, 'needs sharedctypes') @@ -92,7 +90,7 @@ def test_waitfor_timeout(self): # based on test in test/lock_tests.py cond = self.Condition() -@@ -2011,6 +2012,7 @@ class _TestPool(BaseTestCase): +@@ -2304,6 +2305,7 @@ class _TestPool(BaseTestCase): self.assertEqual(get(), 49) self.assertTimingAlmostEqual(get.elapsed, TIMEOUT1) @@ -100,7 +98,7 @@ def test_async_timeout(self): res = self.pool.apply_async(sqr, (6, TIMEOUT2 + 1.0)) get = TimingWrapper(res.get) -@@ -3738,6 +3740,7 @@ class TestWait(unittest.TestCase): +@@ -4039,6 +4041,7 @@ class TestWait(unittest.TestCase): sem.release() time.sleep(period) @@ -108,11 +106,9 @@ def test_wait_integer(self): from multiprocessing.connection import wait -Index: Python-3.6.4/Lib/test/test_asyncio/test_events.py -=================================================================== ---- Python-3.6.4.orig/Lib/test/test_asyncio/test_events.py -+++ Python-3.6.4/Lib/test/test_asyncio/test_events.py -@@ -278,6 +278,7 @@ class EventLoopTestsMixin: +--- a/Lib/test/test_asyncio/test_events.py ++++ b/Lib/test/test_asyncio/test_events.py +@@ -263,6 +263,7 @@ class EventLoopTestsMixin: # Note: because of the default Windows timing granularity of # 15.6 msec, we use fairly long sleep times here (~100 msec). @@ -120,7 +116,7 @@ def test_run_until_complete(self): t0 = self.loop.time() self.loop.run_until_complete(asyncio.sleep(0.1, loop=self.loop)) -@@ -305,7 +306,7 @@ class EventLoopTestsMixin: +@@ -290,7 +291,7 @@ class EventLoopTestsMixin: self.loop.run_forever() t1 = time.monotonic() self.assertEqual(results, ['hello world']) @@ -129,7 +125,7 @@ def test_call_soon(self): results = [] -@@ -549,6 +550,7 @@ class EventLoopTestsMixin: +@@ -576,6 +577,7 @@ class EventLoopTestsMixin: self.assertEqual(caught, 1) @unittest.skipUnless(hasattr(signal, 'SIGALRM'), 'No SIGALRM') @@ -137,3 +133,13 @@ def test_signal_handling_args(self): some_args = (42,) caught = 0 +--- a/Lib/test/test_buffer.py ++++ b/Lib/test/test_buffer.py +@@ -2483,6 +2483,7 @@ class TestBufferProtocol(unittest.TestCa + a = ndarray(items, shape=[2, 2, 2], format="b") + check(memoryview(a), vsize(base_struct + 3 * per_dim)) + ++ @unittest.skip("transient failure on PowerPC") + def test_memoryview_struct_module(self): + + class INT(object): ++++++ subprocess-raise-timeout.patch ++++++ --- /var/tmp/diff_new_pack.6ULy7L/_old 2019-01-28 20:45:31.290089734 +0100 +++ /var/tmp/diff_new_pack.6ULy7L/_new 2019-01-28 20:45:31.290089734 +0100 @@ -1,8 +1,8 @@ -Index: Python-3.6.0/Lib/test/test_subprocess.py +Index: Python-3.7.0/Lib/test/test_subprocess.py =================================================================== ---- Python-3.6.0.orig/Lib/test/test_subprocess.py -+++ Python-3.6.0/Lib/test/test_subprocess.py -@@ -1013,7 +1013,8 @@ class ProcessTestCase(BaseTestCase): +--- Python-3.7.0.orig/Lib/test/test_subprocess.py ++++ Python-3.7.0/Lib/test/test_subprocess.py +@@ -1088,7 +1088,8 @@ class ProcessTestCase(BaseTestCase): self.assertIn("0.0001", str(c.exception)) # For coverage of __str__. # Some heavily loaded buildbots (sparc Debian 3.x) require this much # time to start. @@ -10,5 +10,5 @@ + # OBS might require even more + self.assertEqual(p.wait(timeout=10), 0) - def test_wait_endtime(self): - """Confirm that the deprecated endtime parameter warns.""" + def test_invalid_bufsize(self): + # an invalid type of the bufsize argument should raise
