14
0
Files
python-virtualenv/python-virtualenv.spec
Steve Kowalik 2f63be0b17 - Update to 20.0.33:
* Fix ``None`` type error in cygwin if POSIX path in dest - by :user:`danyeaw`. (`#1962 <https://github.com/pypa/virtualenv/issues/1962>`_)
  * Fix Python 3.4 incompatibilities (added back to the CI) - by :user:`gaborbernat`. (`#1963 <https://github.com/pypa/virtualenv/issues/1963>`_)
  * For activation scripts always use UNIX line endings (unless it's BATCH shell related) - by :user:`saytosid`. (`#1818 <https://github.com/pypa/virtualenv/issues/1818>`_)
  * Avoid spawning new windows when doing seed package upgrades in the background on Windows - by :user:`gaborbernat`. (`#1928 <https://github.com/pypa/virtualenv/issues/1928>`_)
  * Fix a bug that reading and writing on the same file may cause race on multiple processes. (`#1938 <https://github.com/pypa/virtualenv/issues/1938>`_)
  * Provide correct path for bash activator in cygwin or msys2 - by :user:`danyeaw`. (`#1940 <https://github.com/pypa/virtualenv/issues/1940>`_)
  * Relax importlib requirement to allow version<3 - by :user:`usamasadiq` (`#1953 <https://github.com/pypa/virtualenv/issues/1953>`_)
  * pth files were not processed on CPython2 if $PYTHONPATH was pointing to site-packages/ - by :user:`navytux`. (`#1959 <https://github.com/pypa/virtualenv/issues/1959>`_) (`#1960 <https://github.com/pypa/virtualenv/issues/1960>`_)
  * Fix test suite failing if run from system Python - by :user:`gaborbernat`. (`#1882 <https://github.com/pypa/virtualenv/issues/1882>`_)
  * Provide ``setup_logging`` flag to python API so that users can bypass logging handling if their application already
  * performs this - by :user:`gaborbernat`. (`#1896 <https://github.com/pypa/virtualenv/issues/1896>`_)
  * Use ``\n`` instead if ``\r\n`` as line separator for report (because Python already performs this transformation
  * automatically upon write to the logging pipe) - by :user:`gaborbernat`. (`#1905 <https://github.com/pypa/virtualenv/issues/1905>`_)
  * No longer preimport threading to fix support for `gpython <https://pypi.org/project/pygolang/#gpython>`_ and `gevent <https://www.gevent.org/>`_ - by :user:`navytux`. (`#1897 <https://github.com/pypa/virtualenv/issues/1897>`_)
  * Bump dependency ``distutils >= 0.3.1`` - by :user:`gaborbernat`. (`#1880 <https://github.com/pypa/virtualenv/issues/1880>`_)
  * Improve periodic update handling:
    + better logging output while running and enable logging on background process call (``_VIRTUALENV_PERIODIC_UPDATE_INLINE`` may be used to debug behaviour inline)
    + fallback to unverified context when querying the PyPi for release date,
    + stop downloading wheels once we reach the embedded version, by :user:`gaborbernat`. (`#1883 <https://github.com/pypa/virtualenv/issues/1883>`_)
  * Do not print error message if the application exists with ``SystemExit(0)`` - by :user:`gaborbernat`. (`#1885 <https://github.com/pypa/virtualenv/issues/1885>`_)
- Update Requires of python-distlib
- Drop tests.patch, included upstream.

OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-virtualenv?expand=0&rev=88
2020-10-08 09:49:22 +00:00

123 lines
3.9 KiB
RPMSpec

#
# spec file for package python-virtualenv
#
# Copyright (c) 2020 SUSE LLC
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via https://bugs.opensuse.org/
#
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
%global flavor @BUILD_FLAVOR@%{nil}
%if "%{flavor}" == "test"
%define psuffix -test
%bcond_without test
%else
%define psuffix %{nil}
%bcond_with test
%endif
Name: python-virtualenv%{psuffix}
Version: 20.0.33
Release: 0
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
BuildRequires: %{python_module setuptools >= 41.0.0}
BuildRequires: %{python_module setuptools_scm >= 2}
BuildRequires: fdupes
BuildRequires: python-rpm-macros
Requires: python-appdirs >= 1.4.3
Requires: python-distlib >= 0.3.1
Requires: python-filelock >= 3.0.0
Requires: python-importlib-metadata >= 0.12
Requires: python-importlib_resources >= 1.0
Requires: python-setuptools
Requires: python-six >= 1.9.0
Requires(post): update-alternatives
Requires(postun): update-alternatives
BuildArch: noarch
%ifpython2
Requires: python-contextlib2 >= 0.6.0
Requires: python-pathlib2 >= 2.3.3
%endif
%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}}
BuildRequires: fish
BuildRequires: python3-xonsh >= 0.9.13
BuildRequires: tcsh
%endif
%python_subpackages
%description
virtualenv is a tool to create isolated Python environments.
The basic problem being addressed is one of dependencies and versions, and
indirectly permissions. Imagine you have an application that needs version 1
of LibFoo, but another application requires version 2.
Or more generally, what if you want to install an application and leave it be?
If an application works, any change in its libraries or the versions of those
libraries can break the application.
Also, what if you cant install packages into the global site-packages
directory? For instance, on a shared host.
In all these cases, virtualenv can help you. It creates an environment that
has its own installation directories, that doesnt share libraries with other
virtualenv environments (and optionally doesnt use the globally installed
libraries either).
%prep
%setup -q -n virtualenv-%{version}
%build
%python_build
%install
%if !%{with test}
%python_install
%python_expand %fdupes %{buildroot}%{$python_sitelib}
%python_clone -a %{buildroot}%{_bindir}/virtualenv
%endif
%check
%if %{with test}
export LANG="en_US.UTF8"
# test_seed_link_via_app_data - online tests downloads from pypi
%pytest -k 'not test_seed_link_via_app_data'
%endif
%if !%{with test}
%post
%python_install_alternative virtualenv
%postun
%python_uninstall_alternative virtualenv
%files %{python_files}
%license LICENSE
%doc README.md docs/changelog.rst
%{python_sitelib}/virtualenv*
%python_alternative %{_bindir}/virtualenv
%endif
%changelog