From d55c66c8bbc04f8abb71463b0bfd7f7fb06b3def342f46c8faac94ee2d491c3f Mon Sep 17 00:00:00 2001 From: Dirk Mueller Date: Tue, 2 Jun 2020 17:23:14 +0000 Subject: [PATCH 1/4] - update to 20.0.21: - Fix virtualenv fails sometimes when run concurrently, ``--clear-app-data`` conflicts with :option:`clear` flag when abbreviation is turned on. To bypass this while allowing abbreviated flags on the command line we had to move it to :option:`reset-app-data` - by :user:`gaborbernat`. (`#1824 `_) - Fix download fails with python 3.4 - by :user:`gaborbernat`. (`#1809 `_) - Fixes older CPython2 versions use ``_get_makefile_filename`` instead of ``get_makefile_filename`` on ``sysconfig`` - by :user:`ianw`. (`#1810 `_) - Fix download is ``True`` by default - by :user:`gaborbernat`. (`#1813 `_) - Fail ``app-data`` seed operation when wheel download fails and better error message - by :user:`gaborbernat`. (`#1814 `_) - Fix generating a Python 2 environment from Python 3 creates invalid python activator - by :user:`gaborbernat`. (`#1776 `_) - Fix pinning seed packages via ``app-data`` seeder raised ``Invalid Requirement`` - by :user:`gaborbernat`. (`#1779 `_) - Do not stop interpreter discovery if we fail to find the system interpreter for a executable during discovery - by :user:`gaborbernat`. (`#1781 `_) - On CPython2 POSIX platforms ensure ``syconfig.get_makefile_filename`` exists within the virtual environment (this is used by some c-extension based libraries - e.g. numpy - for building) - by :user:`gaborbernat`. (`#1783 `_) - Better handling of options :option:`copies` and :option:`symlinks`. Introduce priority of where the option is set to follow the order: CLI, env var, file, hardcoded. If both set at same level prefers copy over symlink. - by :user:`gaborbernat`. (`#1784 `_) - Upgrade pip for Python ``2.7`` and ``3.5+`` from ``20.0.2`` to ``20.1`` - by :user:`gaborbernat`. (`#1793 `_) - Fix CPython is not discovered from Windows registry, and discover pythons from Windows registry in decreasing order by version - by :user:`gaborbernat`. (`#1796 `_) - Fix symlink detection for creators - by :user:`asottile` (`#1803 `_) - Importing setuptools before cli_run could cause our python information query to fail due to setuptools patching ``distutils.dist.Distribution`` - by :user:`gaborbernat`. (`#1771 `_) OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-virtualenv?expand=0&rev=83 --- python-virtualenv.changes | 26 ++++++++++++++++++++++++++ python-virtualenv.spec | 2 +- virtualenv-20.0.17.tar.gz | 3 --- virtualenv-20.0.21.tar.gz | 3 +++ 4 files changed, 30 insertions(+), 4 deletions(-) delete mode 100644 virtualenv-20.0.17.tar.gz create mode 100644 virtualenv-20.0.21.tar.gz diff --git a/python-virtualenv.changes b/python-virtualenv.changes index 34a12e3..8c8bacb 100644 --- a/python-virtualenv.changes +++ b/python-virtualenv.changes @@ -1,3 +1,29 @@ +------------------------------------------------------------------- +Tue Jun 2 17:21:55 UTC 2020 - Dirk Mueller + +- update to 20.0.21: + - Fix virtualenv fails sometimes when run concurrently, ``--clear-app-data`` conflicts with :option:`clear` flag when + abbreviation is turned on. To bypass this while allowing abbreviated flags on the command line we had to move it to + :option:`reset-app-data` - by :user:`gaborbernat`. (`#1824 `_) + - Fix download fails with python 3.4 - by :user:`gaborbernat`. (`#1809 `_) + - Fixes older CPython2 versions use ``_get_makefile_filename`` instead of ``get_makefile_filename`` on ``sysconfig`` - by :user:`ianw`. (`#1810 `_) + - Fix download is ``True`` by default - by :user:`gaborbernat`. (`#1813 `_) + - Fail ``app-data`` seed operation when wheel download fails and better error message - by :user:`gaborbernat`. (`#1814 `_) + - Fix generating a Python 2 environment from Python 3 creates invalid python activator - by :user:`gaborbernat`. (`#1776 `_) + - Fix pinning seed packages via ``app-data`` seeder raised ``Invalid Requirement`` - by :user:`gaborbernat`. (`#1779 `_) + - Do not stop interpreter discovery if we fail to find the system interpreter for a executable during discovery + - by :user:`gaborbernat`. (`#1781 `_) + - On CPython2 POSIX platforms ensure ``syconfig.get_makefile_filename`` exists within the virtual environment (this is used by some c-extension based libraries - e.g. numpy - for building) - by :user:`gaborbernat`. (`#1783 `_) + - Better handling of options :option:`copies` and :option:`symlinks`. Introduce priority of where the option is set + to follow the order: CLI, env var, file, hardcoded. If both set at same level prefers copy over symlink. - by + :user:`gaborbernat`. (`#1784 `_) + - Upgrade pip for Python ``2.7`` and ``3.5+`` from ``20.0.2`` to ``20.1`` - by :user:`gaborbernat`. (`#1793 `_) + - Fix CPython is not discovered from Windows registry, and discover pythons from Windows registry in decreasing order + by version - by :user:`gaborbernat`. (`#1796 `_) + - Fix symlink detection for creators - by :user:`asottile` (`#1803 `_) + - Importing setuptools before cli_run could cause our python information query to fail due to setuptools patching + ``distutils.dist.Distribution`` - by :user:`gaborbernat`. (`#1771 `_) + ------------------------------------------------------------------- Thu Apr 16 08:31:23 UTC 2020 - Tomáš Chvátal diff --git a/python-virtualenv.spec b/python-virtualenv.spec index b05e42d..f202210 100644 --- a/python-virtualenv.spec +++ b/python-virtualenv.spec @@ -26,7 +26,7 @@ %bcond_with test %endif Name: python-virtualenv%{psuffix} -Version: 20.0.17 +Version: 20.0.21 Release: 0 Summary: Virtual Python Environment builder License: MIT diff --git a/virtualenv-20.0.17.tar.gz b/virtualenv-20.0.17.tar.gz deleted file mode 100644 index fa230ce..0000000 --- a/virtualenv-20.0.17.tar.gz +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:c8364ec469084046c779c9a11ae6340094e8a0bf1d844330fc55c1cefe67c172 -size 7991942 diff --git a/virtualenv-20.0.21.tar.gz b/virtualenv-20.0.21.tar.gz new file mode 100644 index 0000000..c9d743c --- /dev/null +++ b/virtualenv-20.0.21.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a116629d4e7f4d03433b8afa27f43deba09d48bc48f5ecefa4f015a178efb6cf +size 8044843 From 56a8b24ca91cc17733ac83ca764aa88f2a646d09359f5db293f082ed23b33a17 Mon Sep 17 00:00:00 2001 From: Dirk Mueller Date: Wed, 24 Jun 2020 21:04:52 +0000 Subject: [PATCH 2/4] - update to 20.0.25:# * Fix that when the ``app-data`` seeders image creation fails the exception is silently ignored. Avoid two virtual environment creations to step on each oth ers toes by using a lock while creating the base images. By :user:`gaborbernat`. (`#1869 `_) * Ensure that the seeded packages do not get too much out of date: + More details under :ref:`wheels` - by :user:`gaborbernat`. (`#1821 `_) * Upgrade embed wheel content: + - ship wheels for Python ``3.9`` and ``3.10`` + - upgrade setuptools for Python ``3.5+`` from ``47.1.1`` to ``47.3.1`` * Fix typo in ``setup.cfg`` - by :user:`RowdyHowell`. (`#1857 `_) * Relax ``importlib.resources`` requirement to also allow version 2 - by :user:`asottile`. (`#1846 `_) * Upgrade embedded setuptools to ``44.1.1`` for python 2 and ``47.1.1`` for python3.5+ - by :user:`gaborbernat`. (`#1855 `_) OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-virtualenv?expand=0&rev=84 --- python-virtualenv.changes | 15 +++++++++++++++ python-virtualenv.spec | 2 +- virtualenv-20.0.21.tar.gz | 3 --- virtualenv-20.0.25.tar.gz | 3 +++ 4 files changed, 19 insertions(+), 4 deletions(-) delete mode 100644 virtualenv-20.0.21.tar.gz create mode 100644 virtualenv-20.0.25.tar.gz diff --git a/python-virtualenv.changes b/python-virtualenv.changes index 8c8bacb..4ab450e 100644 --- a/python-virtualenv.changes +++ b/python-virtualenv.changes @@ -1,3 +1,18 @@ +------------------------------------------------------------------- +Wed Jun 24 21:01:48 UTC 2020 - Dirk Mueller + +- update to 20.0.25:# + * Fix that when the ``app-data`` seeders image creation fails the exception is silently ignored. Avoid two virtual environment creations to step on each oth +ers toes by using a lock while creating the base images. By :user:`gaborbernat`. (`#1869 `_) + * Ensure that the seeded packages do not get too much out of date: ++ More details under :ref:`wheels` - by :user:`gaborbernat`. (`#1821 `_) + * Upgrade embed wheel content: ++ - ship wheels for Python ``3.9`` and ``3.10`` ++ - upgrade setuptools for Python ``3.5+`` from ``47.1.1`` to ``47.3.1`` + * Fix typo in ``setup.cfg`` - by :user:`RowdyHowell`. (`#1857 `_) + * Relax ``importlib.resources`` requirement to also allow version 2 - by :user:`asottile`. (`#1846 `_) + * Upgrade embedded setuptools to ``44.1.1`` for python 2 and ``47.1.1`` for python3.5+ - by :user:`gaborbernat`. (`#1855 `_) + ------------------------------------------------------------------- Tue Jun 2 17:21:55 UTC 2020 - Dirk Mueller diff --git a/python-virtualenv.spec b/python-virtualenv.spec index f202210..444a5d4 100644 --- a/python-virtualenv.spec +++ b/python-virtualenv.spec @@ -26,7 +26,7 @@ %bcond_with test %endif Name: python-virtualenv%{psuffix} -Version: 20.0.21 +Version: 20.0.25 Release: 0 Summary: Virtual Python Environment builder License: MIT diff --git a/virtualenv-20.0.21.tar.gz b/virtualenv-20.0.21.tar.gz deleted file mode 100644 index c9d743c..0000000 --- a/virtualenv-20.0.21.tar.gz +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:a116629d4e7f4d03433b8afa27f43deba09d48bc48f5ecefa4f015a178efb6cf -size 8044843 diff --git a/virtualenv-20.0.25.tar.gz b/virtualenv-20.0.25.tar.gz new file mode 100644 index 0000000..146e977 --- /dev/null +++ b/virtualenv-20.0.25.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f332ba0b2dfbac9f6b1da9f11224f0036b05cdb4df23b228527c2a2d5504aeed +size 8059847 From bb9d383653bebc22118d01f13661217559f675136fabdbec1c8fd0ce876c38ea Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tom=C3=A1=C5=A1=20Chv=C3=A1tal?= Date: Fri, 3 Jul 2020 11:10:00 +0000 Subject: [PATCH 3/4] - Add missing dependencies - Skip online test test_seed_link_via_app_data - update to 20.0.25: OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-virtualenv?expand=0&rev=85 --- python-virtualenv.changes | 8 +++++++- python-virtualenv.spec | 5 ++++- 2 files changed, 11 insertions(+), 2 deletions(-) diff --git a/python-virtualenv.changes b/python-virtualenv.changes index 4ab450e..4feadda 100644 --- a/python-virtualenv.changes +++ b/python-virtualenv.changes @@ -1,7 +1,13 @@ +------------------------------------------------------------------- +Fri Jul 3 11:08:57 UTC 2020 - Tomáš Chvátal + +- Add missing dependencies +- Skip online test test_seed_link_via_app_data + ------------------------------------------------------------------- Wed Jun 24 21:01:48 UTC 2020 - Dirk Mueller -- update to 20.0.25:# +- update to 20.0.25: * Fix that when the ``app-data`` seeders image creation fails the exception is silently ignored. Avoid two virtual environment creations to step on each oth ers toes by using a lock while creating the base images. By :user:`gaborbernat`. (`#1869 `_) * Ensure that the seeded packages do not get too much out of date: diff --git a/python-virtualenv.spec b/python-virtualenv.spec index 444a5d4..bc17033 100644 --- a/python-virtualenv.spec +++ b/python-virtualenv.spec @@ -53,9 +53,11 @@ Requires: python-pathlib2 >= 2.3.3 %if %{with test} BuildRequires: %{python_module coverage >= 4.5.1} BuildRequires: %{python_module devel} +BuildRequires: %{python_module flaky >= 3} BuildRequires: %{python_module packaging >= 20.0} BuildRequires: %{python_module pytest >= 4.0.0} BuildRequires: %{python_module pytest-env >= 0.6.2} +BuildRequires: %{python_module pytest-freezegun >= 0.4.1} BuildRequires: %{python_module pytest-mock >= 2.0.0} BuildRequires: %{python_module pytest-timeout >= 1.3.4} BuildRequires: %{python_module virtualenv >= %{version}} @@ -99,7 +101,8 @@ libraries either). %check %if %{with test} export LANG="en_US.UTF8" -%pytest +# test_seed_link_via_app_data - online tests downloads from pypi +%pytest -k 'not test_seed_link_via_app_data' %endif %if !%{with test} From e024492b2f8a7ec04e09d84765ddf2ba9c2d59a93f5fb13174f8b5ee0a054cad Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tom=C3=A1=C5=A1=20Chv=C3=A1tal?= Date: Tue, 7 Jul 2020 09:08:27 +0000 Subject: [PATCH 4/4] - Add patch from upstream to fix one failing test: * tests.patch OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-virtualenv?expand=0&rev=86 --- python-virtualenv.changes | 6 +++++ python-virtualenv.spec | 2 ++ tests.patch | 48 +++++++++++++++++++++++++++++++++++++++ 3 files changed, 56 insertions(+) create mode 100644 tests.patch diff --git a/python-virtualenv.changes b/python-virtualenv.changes index 4feadda..b4822bf 100644 --- a/python-virtualenv.changes +++ b/python-virtualenv.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Tue Jul 7 07:20:17 UTC 2020 - Tomáš Chvátal + +- Add patch from upstream to fix one failing test: + * tests.patch + ------------------------------------------------------------------- Fri Jul 3 11:08:57 UTC 2020 - Tomáš Chvátal diff --git a/python-virtualenv.spec b/python-virtualenv.spec index bc17033..299745f 100644 --- a/python-virtualenv.spec +++ b/python-virtualenv.spec @@ -32,6 +32,7 @@ Summary: Virtual Python Environment builder License: MIT URL: http://www.virtualenv.org/ Source: https://files.pythonhosted.org/packages/source/v/virtualenv/virtualenv-%{version}.tar.gz +Patch0: tests.patch BuildRequires: %{python_module setuptools >= 41.0.0} BuildRequires: %{python_module setuptools_scm >= 2} BuildRequires: fdupes @@ -87,6 +88,7 @@ libraries either). %prep %setup -q -n virtualenv-%{version} +%autopatch -p1 %build %python_build diff --git a/tests.patch b/tests.patch new file mode 100644 index 0000000..9cd79fb --- /dev/null +++ b/tests.patch @@ -0,0 +1,48 @@ +From 1f937b09bc268725cfdb09fc88939d1acde24b25 Mon Sep 17 00:00:00 2001 +From: Bernat Gabor +Date: Sat, 4 Jul 2020 17:37:51 +0100 +Subject: [PATCH] Fix test suite failing if run under system Python + +Signed-off-by: Bernat Gabor +--- + docs/changelog/1882.bufix.rst | 1 + + tests/conftest.py | 7 +++++++ + tests/unit/discovery/py_info/test_py_info.py | 2 +- + 3 files changed, 9 insertions(+), 1 deletion(-) + create mode 100644 docs/changelog/1882.bufix.rst + +diff --git a/docs/changelog/1882.bufix.rst b/docs/changelog/1882.bufix.rst +new file mode 100644 +index 000000000..25669a364 +--- /dev/null ++++ b/docs/changelog/1882.bufix.rst +@@ -0,0 +1 @@ ++Fix test suite failing if run from system Python - by :user:`gaborbernat`. +diff --git a/tests/conftest.py b/tests/conftest.py +index 97e109e93..e69e4d72d 100644 +--- a/tests/conftest.py ++++ b/tests/conftest.py +@@ -342,3 +342,10 @@ def cross_python(is_inside_ci, session_app_data): + @pytest.fixture(scope="session") + def for_py_version(): + return "{}.{}".format(*sys.version_info[0:2]) ++ ++ ++@pytest.fixture() ++def skip_if_test_in_system(session_app_data): ++ current = PythonInfo.current(session_app_data) ++ if current.system_executable is not None: ++ pytest.skip("test not valid if run under system") +diff --git a/tests/unit/discovery/py_info/test_py_info.py b/tests/unit/discovery/py_info/test_py_info.py +index 11f3dcc26..6ed11c3e2 100644 +--- a/tests/unit/discovery/py_info/test_py_info.py ++++ b/tests/unit/discovery/py_info/test_py_info.py +@@ -299,7 +299,7 @@ def test_py_info_setuptools(): + PythonInfo() + + +-def test_py_info_to_system_raises(session_app_data, mocker, caplog): ++def test_py_info_to_system_raises(session_app_data, mocker, caplog, skip_if_test_in_system): + caplog.set_level(logging.DEBUG) + mocker.patch.object(PythonInfo, "_find_possible_folders", return_value=[]) + result = PythonInfo.from_exe(sys.executable, app_data=session_app_data, raise_on_error=False)