[packages/python3-voluptuous] - python-voluptuous.spec updated to 0.15.2 for python 3.9+

qboosh qboosh at pld-linux.org
Thu Jul 10 17:47:55 CEST 2025


commit 03cde6fd50aef82cdbe3479e7c8367a8e8ac7cb7
Author: Jakub Bogusz <qboosh at pld-linux.org>
Date:   Thu Jul 10 17:49:27 2025 +0200

    - python-voluptuous.spec updated to 0.15.2 for python 3.9+

 python-voluptuous-py2-tests.patch |  12 ----
 python-voluptuous.spec            | 117 --------------------------------------
 python3-voluptuous.spec           |  60 +++++++++++++++++++
 3 files changed, 60 insertions(+), 129 deletions(-)
---
diff --git a/python-voluptuous.spec b/python-voluptuous.spec
deleted file mode 100644
index 2170157..0000000
--- a/python-voluptuous.spec
+++ /dev/null
@@ -1,117 +0,0 @@
-#
-# Conditional build:
-%bcond_without	tests	# unit tests
-%bcond_without	python2 # CPython 2.x module
-%bcond_without	python3 # CPython 3.x module
-
-Summary:	Python data validation library
-Summary(pl.UTF-8):	Biblioteka Pythona do sprawdzania poprawności danych
-Name:		python-voluptuous
-# keep 0.13.x here for python2 support
-Version:	0.13.1
-Release:	3
-License:	BSD
-Group:		Libraries/Python
-#Source0Download: https://pypi.org/simple/voluptuous/
-Source0:	https://files.pythonhosted.org/packages/source/v/voluptuous/voluptuous-%{version}.tar.gz
-# Source0-md5:	78d39d2a15e3717ab8d100944da60d11
-Patch0:		%{name}-py2-tests.patch
-URL:		https://pypi.org/project/voluptuous/
-%if %{with python2}
-BuildRequires:	python-modules >= 1:2.7
-BuildRequires:	python-setuptools
-%if %{with tests}
-BuildRequires:	python-pytest
-%endif
-%endif
-%if %{with python3}
-BuildRequires:	python3-modules >= 1:3.6
-BuildRequires:	python3-setuptools
-%if %{with tests}
-BuildRequires:	python3-pytest
-%endif
-%endif
-BuildRequires:	rpm-pythonprov
-BuildRequires:	rpmbuild(macros) >= 1.714
-Requires:	python-modules >= 1:2.7
-BuildArch:	noarch
-BuildRoot:	%{tmpdir}/%{name}-%{version}-root-%(id -u -n)
-
-%description
-Voluptuous is a Python data validation library. It is primarily
-intended for validating data coming into Python as JSON, YAML, etc.
-
-%description -l pl.UTF-8
-Voluptuous to biblioteka Pythona do sprawdzania poprawności danych.
-Jest przeznaczona głównie do sprawdzania danych pochodzących z
-formatów JSON, YAML itp.
-
-%package -n python3-voluptuous
-Summary:	Python data validation library
-Summary(pl.UTF-8):	Biblioteka Pythona do sprawdzania poprawności danych
-Group:		Libraries/Python
-Requires:	python3-modules >= 1:3.6
-
-%description -n python3-voluptuous
-Voluptuous is a Python data validation library. It is primarily
-intended for validating data coming into Python as JSON, YAML, etc.
-
-%description -n python3-voluptuous -l pl.UTF-8
-Voluptuous to biblioteka Pythona do sprawdzania poprawności danych.
-Jest przeznaczona głównie do sprawdzania danych pochodzących z
-formatów JSON, YAML itp.
-
-%prep
-%setup -q -n voluptuous-%{version}
-%patch -P 0 -p1
-
-%build
-%if %{with python2}
-%py_build
-
-%if %{with tests}
-PYTEST_DISABLE_PLUGIN_AUTOLOAD=1 \
-%{__python} -m pytest voluptuous/tests/tests.py
-%endif
-%endif
-
-%if %{with python3}
-%py3_build
-
-%if %{with tests}
-PYTEST_DISABLE_PLUGIN_AUTOLOAD=1 \
-%{__python3} -m pytest voluptuous/tests/tests.py
-%endif
-%endif
-
-%install
-rm -rf $RPM_BUILD_ROOT
-
-%if %{with python2}
-%py_install
-
-%py_postclean
-%endif
-
-%if %{with python3}
-%py3_install
-%endif
-
-%clean
-rm -rf $RPM_BUILD_ROOT
-
-%if %{with python2}
-%files
-%defattr(644,root,root,755)
-%doc CHANGELOG.md COPYING README.md
-%{py_sitescriptdir}/voluptuous
-%{py_sitescriptdir}/voluptuous-%{version}-py*.egg-info
-%endif
-
-%if %{with python3}
-%files -n python3-voluptuous
-%defattr(644,root,root,755)
-%doc CHANGELOG.md COPYING README.md
-%{py3_sitescriptdir}/voluptuous
-%{py3_sitescriptdir}/voluptuous-%{version}-py*.egg-info
-%endif
diff --git a/python3-voluptuous.spec b/python3-voluptuous.spec
new file mode 100644
index 0000000..a54b558
--- /dev/null
+++ b/python3-voluptuous.spec
@@ -0,0 +1,60 @@
+#
+# Conditional build:
+%bcond_without	tests	# unit tests
+
+Summary:	Python data validation library
+Summary(pl.UTF-8):	Biblioteka Pythona do sprawdzania poprawności danych
+Name:		python3-voluptuous
+Version:	0.15.2
+Release:	1
+License:	BSD
+Group:		Libraries/Python
+#Source0Download: https://pypi.org/simple/voluptuous/
+Source0:	https://files.pythonhosted.org/packages/source/v/voluptuous/voluptuous-%{version}.tar.gz
+# Source0-md5:	d963b2b4f3f2c6489e85f32605418964
+URL:		https://pypi.org/project/voluptuous/
+BuildRequires:	python3-modules >= 1:3.9
+BuildRequires:	python3-setuptools
+BuildRequires:	python3-wheel
+%if %{with tests}
+BuildRequires:	python3-pytest
+%endif
+BuildRequires:	rpm-pythonprov
+BuildRequires:	rpmbuild(macros) >= 1.714
+Requires:	python3-modules >= 1:3.9
+BuildArch:	noarch
+BuildRoot:	%{tmpdir}/%{name}-%{version}-root-%(id -u -n)
+
+%description
+Voluptuous is a Python data validation library. It is primarily
+intended for validating data coming into Python as JSON, YAML, etc.
+
+%description -l pl.UTF-8
+Voluptuous to biblioteka Pythona do sprawdzania poprawności danych.
+Jest przeznaczona głównie do sprawdzania danych pochodzących z
+formatów JSON, YAML itp.
+
+%prep
+%setup -q -n voluptuous-%{version}
+
+%build
+%py3_build
+
+%if %{with tests}
+PYTEST_DISABLE_PLUGIN_AUTOLOAD=1 \
+%{__python3} -m pytest voluptuous/tests/tests.py
+%endif
+
+%install
+rm -rf $RPM_BUILD_ROOT
+
+%py3_install
+
+%clean
+rm -rf $RPM_BUILD_ROOT
+
+%files
+%defattr(644,root,root,755)
+%doc CHANGELOG.md COPYING README.md
+%{py3_sitescriptdir}/voluptuous
+%{py3_sitescriptdir}/voluptuous-%{version}-py*.egg-info
diff --git a/python-voluptuous-py2-tests.patch b/python-voluptuous-py2-tests.patch
deleted file mode 100644
index 6fb011d..0000000
--- a/python-voluptuous-py2-tests.patch
+++ /dev/null
@@ -1,12 +0,0 @@
---- voluptuous-0.13.1/voluptuous/tests/tests.py.orig	2022-04-07 13:59:22.000000000 +0200
-+++ voluptuous-0.13.1/voluptuous/tests/tests.py	2024-01-17 19:44:32.696930299 +0100
-@@ -1630,7 +1630,8 @@ if Enum:
-         try:
-             string_schema("hello")
-         except Invalid as e:
--            assert str(e) == "expected StringChoice or one of 'easy', 'medium', 'hard'"
-+            assert str(e) in ["expected StringChoice or one of 'easy', 'medium', 'hard'",
-+                              "expected StringChoice or one of 'easy', 'hard', 'medium'"]
-         else:
-             assert False, "Did not raise Invalid for String"
- 
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/python3-voluptuous.git/commitdiff/03cde6fd50aef82cdbe3479e7c8367a8e8ac7cb7



More information about the pld-cvs-commit mailing list