Compare commits
No commits in common. 'cs10' and 'c9' have entirely different histories.
@ -1 +1 @@
|
||||
SOURCES/resolvelib-1.0.1.tar.gz
|
||||
SOURCES/resolvelib-d935f9fd07246d9641436c7a8e6ae39423374e28.tar.gz
|
||||
|
@ -1 +1 @@
|
||||
648153875ad2f5553ab50f8b4d5b6bfb494282b2 SOURCES/resolvelib-1.0.1.tar.gz
|
||||
2203e09b2add3d1edceb28e20b2a091e5e6c0344 SOURCES/resolvelib-d935f9fd07246d9641436c7a8e6ae39423374e28.tar.gz
|
||||
|
@ -1,63 +0,0 @@
|
||||
From 3e50054d836b655b0868520bae8b85a3c18967ef Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Miro=20Hron=C4=8Dok?= <miro@hroncok.cz>
|
||||
Date: Wed, 8 Nov 2023 17:12:16 +0100
|
||||
Subject: [PATCH] Replace the commentjson test dependency with re.sub
|
||||
|
||||
While at it, only open the json files once.
|
||||
|
||||
Co-authored-by: Maxwell G <maxwell@gtmx.me>
|
||||
---
|
||||
setup.cfg | 1 -
|
||||
.../cocoapods/test_resolvers_cocoapods.py | 19 +++++++++++--------
|
||||
2 files changed, 11 insertions(+), 9 deletions(-)
|
||||
|
||||
diff --git a/setup.cfg b/setup.cfg
|
||||
index 5eddf2f..e080991 100644
|
||||
--- a/setup.cfg
|
||||
+++ b/setup.cfg
|
||||
@@ -44,7 +44,6 @@ lint =
|
||||
isort
|
||||
types-requests
|
||||
test =
|
||||
- commentjson
|
||||
packaging
|
||||
pytest
|
||||
release =
|
||||
diff --git a/tests/functional/cocoapods/test_resolvers_cocoapods.py b/tests/functional/cocoapods/test_resolvers_cocoapods.py
|
||||
index 12dff46..f54e27d 100644
|
||||
--- a/tests/functional/cocoapods/test_resolvers_cocoapods.py
|
||||
+++ b/tests/functional/cocoapods/test_resolvers_cocoapods.py
|
||||
@@ -5,7 +5,6 @@
|
||||
import re
|
||||
import string
|
||||
|
||||
-import commentjson # type: ignore
|
||||
import pytest
|
||||
|
||||
from resolvelib import AbstractProvider, ResolutionImpossible, Resolver
|
||||
@@ -124,14 +123,18 @@ def _version_in_specset(version, specset):
|
||||
|
||||
|
||||
def _safe_json_load(filename):
|
||||
- # Some fixtures has comments so the stdlib implementation doesn't work.
|
||||
- # We only use commentjson if we absolutely need to because it's SLOW.
|
||||
- try:
|
||||
- with open(filename) as f:
|
||||
+ # Some fixtures have comments so they are not valid json.
|
||||
+ # We could use commentjson/json5 to load them,
|
||||
+ # but it's easier to strip the comments.
|
||||
+ # We only do it when json.load() fails to avoid unnecessary loading
|
||||
+ # all the json files to strings.
|
||||
+ with open(filename) as f:
|
||||
+ try:
|
||||
data = json.load(f)
|
||||
- except ValueError:
|
||||
- with open(filename) as f:
|
||||
- data = commentjson.load(f)
|
||||
+ except ValueError:
|
||||
+ f.seek(0)
|
||||
+ strippedjson = re.sub(r"//.*$", "", f.read(), flags=re.MULTILINE)
|
||||
+ data = json.loads(strippedjson)
|
||||
return data
|
||||
|
||||
|
@ -1,109 +1,74 @@
|
||||
# Created by pyp2rpm-3.3.6
|
||||
%global pypi_name resolvelib
|
||||
%global forgeurl https://github.com/sarugaku/resolvelib
|
||||
%bcond tests 1
|
||||
%global python3_pkgversion 3
|
||||
%global python39_sitelib /usr/lib/python3.9/site-packages/
|
||||
%global commitId d935f9fd07246d9641436c7a8e6ae39423374e28
|
||||
|
||||
Name: python-%{pypi_name}
|
||||
Version: 1.0.1
|
||||
%global tag %{version}
|
||||
%forgemeta
|
||||
Release: 6%{?dist}
|
||||
Version: 0.5.4
|
||||
Release: 5%{?dist}
|
||||
Summary: Resolve abstract dependencies into concrete ones
|
||||
|
||||
License: ISC
|
||||
URL: %{forgeurl}
|
||||
Source: %{forgesource}
|
||||
# Avoid commentjson/json5 build dependency just for a couple tests
|
||||
Patch: %{url}/pull/141.patch#/remove-commentjson-dep.patch
|
||||
|
||||
URL: https://github.com/sarugaku/resolvelib.git
|
||||
Source0: resolvelib-d935f9fd07246d9641436c7a8e6ae39423374e28.tar.gz
|
||||
BuildArch: noarch
|
||||
|
||||
BuildRequires: python3-devel
|
||||
BuildRequires: python%{python3_pkgversion}-devel
|
||||
BuildRequires: python%{python3_pkgversion}-rpm-macros
|
||||
BuildRequires: python%{python3_pkgversion}-setuptools
|
||||
|
||||
%global _description %{expand:
|
||||
%description
|
||||
ResolveLib at the highest level provides a Resolver class that
|
||||
includes dependency resolution logic. You give it some things, and a little
|
||||
information on how it should interact with them, and it will spit out a
|
||||
resolution result. Intended Usage :: import resolvelib Things I want to
|
||||
resolve. requirements [...] Implement logic so the resolver understands the
|
||||
requirement format. class...}
|
||||
|
||||
%description %_description
|
||||
requirement format. class...
|
||||
|
||||
|
||||
%package -n python3-%{pypi_name}
|
||||
%package -n python%{python3_pkgversion}-%{pypi_name}
|
||||
Summary: %{summary}
|
||||
|
||||
%description -n python3-%{pypi_name} %{_description}
|
||||
|
||||
%{?python_provide:%python_provide python%{python3_pkgversion}-%{pypi_name}}
|
||||
|
||||
#Requires: python3dist(black)
|
||||
#Requires: python3dist(commentjson)
|
||||
#Requires: python3dist(flake8)
|
||||
#Requires: python3dist(html5lib)
|
||||
#Requires: python3dist(packaging)
|
||||
#Requires: python3dist(packaging)
|
||||
#Requires: python3dist(pygraphviz)
|
||||
#Requires: python3dist(pytest)
|
||||
#Requires: python3dist(requests)
|
||||
#Requires: python3dist(setl)
|
||||
#Requires: python3dist(towncrier)
|
||||
|
||||
%description -n python%{python3_pkgversion}-%{pypi_name}
|
||||
ResolveLib at the highest level provides a Resolver class that
|
||||
includes dependency resolution logic. You give it some things, and a little
|
||||
information on how it should interact with them, and it will spit out a
|
||||
resolution result. Intended Usage :: import resolvelib Things I want to
|
||||
resolve. requirements [...] Implement logic so the resolver understands the
|
||||
requirement format. class...
|
||||
|
||||
%prep
|
||||
%autosetup %{forgesetupargs} -p1
|
||||
|
||||
|
||||
%generate_buildrequires
|
||||
%pyproject_buildrequires %{?with_tests:-x test}
|
||||
|
||||
%autosetup -n %{pypi_name}-%{commitId}
|
||||
# Remove bundled egg-info
|
||||
rm -rf %{pypi_name}.egg-info
|
||||
|
||||
%build
|
||||
%pyproject_wheel
|
||||
|
||||
%py3_build
|
||||
|
||||
%install
|
||||
%pyproject_install
|
||||
%pyproject_save_files %{pypi_name}
|
||||
|
||||
%check
|
||||
%pytest -v
|
||||
|
||||
%py3_install
|
||||
|
||||
%files -n python3-%{pypi_name} -f %{pyproject_files}
|
||||
%files -n python%{python3_pkgversion}-%{pypi_name}
|
||||
%license LICENSE
|
||||
%doc README.rst
|
||||
|
||||
%{python39_sitelib}/%{pypi_name}
|
||||
%{python39_sitelib}/%{pypi_name}-%{version}-py%{python3_version}.egg-info
|
||||
|
||||
%changelog
|
||||
* Tue Oct 29 2024 Troy Dawson <tdawson@redhat.com> - 1.0.1-6
|
||||
- Bump release for October 2024 mass rebuild:
|
||||
Resolves: RHEL-64018
|
||||
|
||||
* Mon Jun 24 2024 Troy Dawson <tdawson@redhat.com> - 1.0.1-5
|
||||
- Bump release for June 2024 mass rebuild
|
||||
|
||||
* Fri Jan 26 2024 Fedora Release Engineering <releng@fedoraproject.org> - 1.0.1-4
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild
|
||||
|
||||
* Mon Jan 22 2024 Fedora Release Engineering <releng@fedoraproject.org> - 1.0.1-3
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild
|
||||
|
||||
* Tue Nov 07 2023 Yaakov Selkowitz <yselkowi@redhat.com> - 1.0.1-2
|
||||
- Simplify build dependencies
|
||||
|
||||
* Fri Oct 20 2023 Maxwell G <maxwell@gtmx.me> - 1.0.1-1
|
||||
- Update to 1.0.1.
|
||||
|
||||
* Fri Jul 21 2023 Fedora Release Engineering <releng@fedoraproject.org> - 0.5.5-9
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild
|
||||
|
||||
* Tue Jun 13 2023 Python Maint <python-maint@redhat.com> - 0.5.5-8
|
||||
- Rebuilt for Python 3.12
|
||||
|
||||
* Fri Jan 20 2023 Fedora Release Engineering <releng@fedoraproject.org> - 0.5.5-7
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild
|
||||
|
||||
* Fri Jul 22 2022 Fedora Release Engineering <releng@fedoraproject.org> - 0.5.5-6
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild
|
||||
|
||||
* Mon Jun 13 2022 Python Maint <python-maint@redhat.com> - 0.5.5-5
|
||||
- Rebuilt for Python 3.11
|
||||
|
||||
* Fri Jan 21 2022 Fedora Release Engineering <releng@fedoraproject.org> - 0.5.5-4
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild
|
||||
|
||||
* Fri Jul 23 2021 Fedora Release Engineering <releng@fedoraproject.org> - 0.5.5-3
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild
|
||||
|
||||
* Fri Jun 04 2021 Python Maint <python-maint@redhat.com> - 0.5.5-2
|
||||
- Rebuilt for Python 3.10
|
||||
|
||||
* Sat Apr 10 2021 Kevin Fenzi <kevin@scrye.com> - 0.5.5-1
|
||||
* Mon Jun 14 2021 Paul Belanger <pabelanger@redhat.com> - 0.5.4-1
|
||||
- Initial package.
|
||||
- Forked from https://fedora.pkgs.org/rawhide/fedora-x86_64/python3-resolvelib-0.5.5-2.fc35.noarch.rpm.html however
|
||||
downgraded to 0.5.4 due to 0.5.5 being yanked from pypi.
|
||||
|
Loading…
Reference in new issue