14
0
forked from pool/python-semver

Accepting request 945413 from devel:languages:python

- fix support for Python 3.10 with update to development version:

OBS-URL: https://build.opensuse.org/request/show/945413
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-semver?expand=0&rev=16
This commit is contained in:
2022-01-10 22:54:02 +00:00
committed by Git OBS Bridge
4 changed files with 103 additions and 9 deletions

View File

@@ -1,3 +1,96 @@
-------------------------------------------------------------------
Mon Jan 10 21:27:18 UTC 2022 - Sebastian Wagner <sebix+novell.com@sebix.at>
- fix support for Python 3.10 with update to development version:
- update to revision g4d2df08:
- Changes for the upcoming release can be found in:
- the `"changelog.d" directory <https://github.com/python-semver/python-semver/tree/master/changelog.d>`_:
- in our repository.:
- update to version 3.0.0-dev.2:
- Deprecations:
- :gh:`169`: Deprecate CLI functions not imported from ``semver.cli``.
- Features:
- :gh:`169`: Create semver package and split code among different modules in the packages.
* Remove :file:`semver.py`
* Create :file:`src/semver/__init__.py`
* Create :file:`src/semver/cli.py` for all CLI methods
* Create :file:`src/semver/_deprecated.py` for the ``deprecated`` decorator and other deprecated functions
* Create :file:`src/semver/__main__.py` to allow calling the CLI using :command:`python -m semver`
* Create :file:`src/semver/_types.py` to hold type aliases
* Create :file:`src/semver/version.py` to hold the :class:`Version` class (old name :class:`VersionInfo`) and its utility functions
* Create :file:`src/semver/__about__.py` for all the metadata variables
- :gh:`305`: Rename :class:`VersionInfo` to :class:`Version` but keep an alias for compatibility
- Improved Documentation:
- :gh:`304`: Several improvements in documentation:
* Reorganize API documentation.
* Add migration chapter from semver2 to semver3.
* Distinguish between changlog for version 2 and 3
- :gh:`305`: Add note about :class:`Version` rename.
- Trivial/Internal Changes:
- :gh:`169`: Adapted infrastructure code to the new project layout.
* Replace :file:`setup.py` with :file:`setup.cfg` because the :file:`setup.cfg` is easier to use
* Adapt documentation code snippets where needed
* Adapt tests
* Changed the ``deprecated`` to hardcode the ``semver`` package name in the warning.
Increase coverage to 100% for all non-deprecated APIs
- :gh:`304`: Support PEP-561 :file:`py.typed`.
According to the mentioned PEP:
"Package maintainers who wish to support type checking
of their code MUST add a marker file named :file:`py.typed`
to their package supporting typing."
Add package_data to :file:`setup.cfg` to include this marker in dist
and whl file.
- update to version 3.0.0-dev.1:
- Deprecations:
- :pr:`290`: For semver 3.0.0-alpha0:
* Remove anything related to Python2
* In :file:`tox.ini` and :file:`.travis.yml`
Remove targets py27, py34, py35, and pypy.
Add py38, py39, and nightly (allow to fail)
* In :file:`setup.py` simplified file and remove
``Tox`` and ``Clean`` classes
* Remove old Python versions (2.7, 3.4, 3.5, and pypy)
from Travis
- :gh:`234`: In :file:`setup.py` simplified file and remove
``Tox`` and ``Clean`` classes
- Features:
- :pr:`290`: Create semver 3.0.0-alpha0
* Update :file:`README.rst`, mention maintenance
branch ``maint/v2``.
* Remove old code mainly used for Python2 compatibility,
adjusted code to support Python3 features.
* Split test suite into separate files under :file:`tests/`
directory
* Adjust and update :file:`setup.py`. Requires Python >=3.6.*
Extract metadata directly from source (affects all the ``__version__``,
``__author__`` etc. variables)
- :gh:`270`: Configure Towncrier (:pr:`273`:)
* Add :file:`changelog.d/.gitignore` to keep this directory
* Create :file:`changelog.d/README.rst` with some descriptions
* Add :file:`changelog.d/_template.rst` as Towncrier template
* Add ``[tool.towncrier]`` section in :file:`pyproject.toml`
* Add "changelog" target into :file:`tox.ini`. Use it like
:command:`tox -e changelog -- CMD` whereas ``CMD`` is a
Towncrier command. The default :command:`tox -e changelog`
calls Towncrier to create a draft of the changelog file
and output it to stdout.
* Update documentation and add include a new section
"Changelog" included from :file:`changelog.d/README.rst`.
- :gh:`276`: Document how to create a sublass from :class:`VersionInfo` class
- :gh:`213`: Add typing information
- Bug Fixes:
- :gh:`291`: Disallow negative numbers in VersionInfo arguments
for ``major``, ``minor``, and ``patch``.
- Improved Documentation:
- :pr:`290`: Several improvements in the documentation:
* New layout to distinguish from the semver2 development line.
* Create new logo.
* Remove any occurances of Python2.
* Describe changelog process with Towncrier.
* Update the release process.
- Trivial/Internal Changes:
- :pr:`290`: Add supported Python versions to :command:`black`.
------------------------------------------------------------------- -------------------------------------------------------------------
Wed Jan 13 09:28:26 UTC 2021 - John Vandenberg <jayvdb@gmail.com> Wed Jan 13 09:28:26 UTC 2021 - John Vandenberg <jayvdb@gmail.com>

View File

@@ -1,7 +1,7 @@
# #
# spec file for package python-semver # spec file for package python-semver
# #
# Copyright (c) 2020 SUSE LLC # Copyright (c) 2022 SUSE LLC
# #
# All modifications and additions to the file contributed by third parties # All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed # remain the property of their copyright owners, unless otherwise agreed
@@ -19,19 +19,20 @@
%{?!python_module:%define python_module() python-%{**} python3-%{**}} %{?!python_module:%define python_module() python-%{**} python3-%{**}}
%bcond_without test %bcond_without test
Name: python-semver Name: python-semver
Version: 2.13.0 Version: 3.0.0~dev.2+41+g4d2df08
Release: 0 Release: 0
Summary: Python helper for Semantic Versioning Summary: Python helper for Semantic Versioning
License: BSD-3-Clause License: BSD-3-Clause
Group: Development/Languages/Python Group: Development/Languages/Python
URL: https://github.com/python-semver/python-semver URL: https://github.com/python-semver/python-semver
Source: https://files.pythonhosted.org/packages/source/s/semver/semver-%{version}.tar.gz #Source: https://files.pythonhosted.org/packages/source/s/semver/semver-%%{version}.tar.gz
Source: https://github.com/python-semver/python-semver/archive/refs/heads/feature/tests-for-py310.tar.gz#/semver-%{version}.tar.gz
BuildRequires: %{python_module pytest} BuildRequires: %{python_module pytest}
BuildRequires: %{python_module setuptools} BuildRequires: %{python_module setuptools}
BuildRequires: fdupes BuildRequires: fdupes
BuildRequires: python-rpm-macros BuildRequires: python-rpm-macros
Requires(post): update-alternatives Requires(post): update-alternatives
Requires(postun): update-alternatives Requires(postun):update-alternatives
# See https://github.com/k-bx/python-semver/issues/67 for why conflicts is needed # See https://github.com/k-bx/python-semver/issues/67 for why conflicts is needed
Conflicts: python-node-semver Conflicts: python-node-semver
BuildArch: noarch BuildArch: noarch
@@ -42,7 +43,7 @@ A Python module for semantic versioning. Simplifies comparing versions.
See also http://semver.org/ See also http://semver.org/
%prep %prep
%setup -q -n semver-%{version} %setup -q -n python-semver-feature-tests-for-py310
sed -i '/-cov/d' setup.cfg sed -i '/-cov/d' setup.cfg
%build %build
@@ -66,7 +67,7 @@ sed -i '/-cov/d' setup.cfg
%files %{python_files} %files %{python_files}
%doc README.rst %doc README.rst
%{python_sitelib}/semver* %{python_sitelib}/semver*
%pycache_only %{python_sitelib}/__pycache__/semver* #%%pycache_only %%{python_sitelib}/__pycache__/semver*
%python_alternative %{_bindir}/pysemver %python_alternative %{_bindir}/pysemver
%changelog %changelog

View File

@@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:fa0fe2722ee1c3f57eac478820c3a5ae2f624af8264cbdf9000c980ff7f75e3f
size 45816

View File

@@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:1d49098227c5bb9c2e538974f2db56b4e6d981830257bb8e47f3593431595253
size 56475