From 7826b7a96d7fc2971d0136f3c9e552b01ec865ce157960fc6811698b32f75b34 Mon Sep 17 00:00:00 2001 From: Matej Cepl Date: Mon, 30 Jun 2025 12:57:32 +0000 Subject: [PATCH] Accepting request 1289225 from home:glaubitz:branches:devel:languages:python - Update to 3.3.1 OAuth2.0 Client: * #906: fix regression of expires_in parsing when float in string. - from version 3.3.0 OAuth2.0 Provider: * OIDC: #879 Changed in how ui_locales is parsed * RFC8628: Added OAuth2.0 Device Authorization Grant support * PKCE: #876, #893 Fixed `create_code_verifier` length * OIDC: Pre-configured OIDC server to use Refresh Token by default OAuth2.0 Common: * OAuth2Error: Allow 0 to be a valid state OAuth2.0 Client: * #745: expires_at is forced to be an int * #899: expires_at clarification General: * Removed Python 3.5, 3.6, 3.7 support * #859, #883: Added Python 3.12, 3.13 Support * Added dependency-review GitHub Action * Updated various references of license (SPDX identifier..) * Added GitHub Action for lint, replaced bandy with ruff, removed isort... * Migrated to GitHub Actions from Travis * Added Security Policy - Drop support for older Python versions - Drop Make-UtilsTests.test_filter_params-Python-3.13-compatible.patch, merged upstream - Remove unneeded workaround to recompile Python sources - Switch build system from setuptools to pyproject.toml * Add python-pip and python-wheel to BuildRequires * Replace %python_build with %pyproject_wheel * Replace %python_install with %pyproject_install OBS-URL: https://build.opensuse.org/request/show/1289225 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-oauthlib?expand=0&rev=69 --- ...filter_params-Python-3.13-compatible.patch | 37 ------------------- oauthlib-3.2.2.tar.gz | 3 -- oauthlib-3.3.1.tar.gz | 3 ++ python-oauthlib.changes | 35 ++++++++++++++++++ python-oauthlib.spec | 25 ++++--------- 5 files changed, 46 insertions(+), 57 deletions(-) delete mode 100644 Make-UtilsTests.test_filter_params-Python-3.13-compatible.patch delete mode 100644 oauthlib-3.2.2.tar.gz create mode 100644 oauthlib-3.3.1.tar.gz diff --git a/Make-UtilsTests.test_filter_params-Python-3.13-compatible.patch b/Make-UtilsTests.test_filter_params-Python-3.13-compatible.patch deleted file mode 100644 index 87458db..0000000 --- a/Make-UtilsTests.test_filter_params-Python-3.13-compatible.patch +++ /dev/null @@ -1,37 +0,0 @@ -From 6cbbd16bf7ac0ee6af68dc900cbaa734c52343c8 Mon Sep 17 00:00:00 2001 -From: =?UTF-8?q?Miro=20Hron=C4=8Dok?= -Date: Tue, 24 Oct 2023 15:08:10 +0200 -Subject: [PATCH] Make UtilsTests.test_filter_params Python 3.13+ compatible - -Since Python 3.13.0a1, docstrings are automatically dedented. -See https://github.com/python/cpython/issues/81283 -and https://docs.python.org/3.13/whatsnew/3.13.html#other-language-changes - -As a result, using a docstring with leading space as a test case -breaks the test assumption. - -The initial commit which introduced this test a decade ago -(6c0c7914f3a57823834b1be492b307992f943629) -does not specify why testing the spaces is important. ---- - tests/oauth1/rfc5849/test_utils.py | 4 ++-- - 1 file changed, 2 insertions(+), 2 deletions(-) - -diff --git a/tests/oauth1/rfc5849/test_utils.py b/tests/oauth1/rfc5849/test_utils.py -index 013c71a9..22128908 100644 ---- a/tests/oauth1/rfc5849/test_utils.py -+++ b/tests/oauth1/rfc5849/test_utils.py -@@ -53,11 +53,11 @@ def test_filter_params(self): - # The following is an isolated test function used to test the filter_params decorator. - @filter_params - def special_test_function(params, realm=None): -- """ I am a special test function """ -+ """I am a special test function""" - return 'OAuth ' + ','.join(['='.join([k, v]) for k, v in params]) - - # check that the docstring got through -- self.assertEqual(special_test_function.__doc__, " I am a special test function ") -+ self.assertEqual(special_test_function.__doc__, "I am a special test function") - - # Check that the decorator filtering works as per design. - # Any param that does not start with 'oauth' diff --git a/oauthlib-3.2.2.tar.gz b/oauthlib-3.2.2.tar.gz deleted file mode 100644 index d1f3823..0000000 --- a/oauthlib-3.2.2.tar.gz +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:9859c40929662bec5d64f34d01c99e093149682a3f38915dc0655d5a633dd918 -size 177352 diff --git a/oauthlib-3.3.1.tar.gz b/oauthlib-3.3.1.tar.gz new file mode 100644 index 0000000..7552196 --- /dev/null +++ b/oauthlib-3.3.1.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0f0f8aa759826a193cf66c12ea1af1637f87b9b4622d46e866952bb022e538c9 +size 185918 diff --git a/python-oauthlib.changes b/python-oauthlib.changes index 5f017cd..8b3126a 100644 --- a/python-oauthlib.changes +++ b/python-oauthlib.changes @@ -1,3 +1,38 @@ +------------------------------------------------------------------- +Mon Jun 30 09:16:42 UTC 2025 - John Paul Adrian Glaubitz + +- Update to 3.3.1 + OAuth2.0 Client: + * #906: fix regression of expires_in parsing when float in string. +- from version 3.3.0 + OAuth2.0 Provider: + * OIDC: #879 Changed in how ui_locales is parsed + * RFC8628: Added OAuth2.0 Device Authorization Grant support + * PKCE: #876, #893 Fixed `create_code_verifier` length + * OIDC: Pre-configured OIDC server to use Refresh Token by default + OAuth2.0 Common: + * OAuth2Error: Allow 0 to be a valid state + OAuth2.0 Client: + * #745: expires_at is forced to be an int + * #899: expires_at clarification + General: + * Removed Python 3.5, 3.6, 3.7 support + * #859, #883: Added Python 3.12, 3.13 Support + * Added dependency-review GitHub Action + * Updated various references of license (SPDX identifier..) + * Added GitHub Action for lint, replaced bandy with ruff, removed isort... + * Migrated to GitHub Actions from Travis + * Added Security Policy +- Drop support for older Python versions +- Drop Make-UtilsTests.test_filter_params-Python-3.13-compatible.patch, + merged upstream +- Remove unneeded workaround to recompile Python sources +- Switch build system from setuptools to pyproject.toml + * Add python-pip and python-wheel to BuildRequires + * Replace %python_build with %pyproject_wheel + * Replace %python_install with %pyproject_install + * Update name for dist directory in %files section + ------------------------------------------------------------------- Tue Sep 24 12:27:53 UTC 2024 - ecsos diff --git a/python-oauthlib.spec b/python-oauthlib.spec index bd6fae2..1fcf42a 100644 --- a/python-oauthlib.spec +++ b/python-oauthlib.spec @@ -1,7 +1,7 @@ # # spec file for package python-oauthlib # -# Copyright (c) 2024 SUSE LLC +# Copyright (c) 2025 SUSE LLC # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -16,24 +16,23 @@ # -%define skip_python2 1 %{?sle15_python_module_pythons} Name: python-oauthlib -Version: 3.2.2 +Version: 3.3.1 Release: 0 Summary: A Generic Implementation of the OAuth Request-Signing Logic License: BSD-3-Clause Group: Development/Languages/Python URL: https://github.com/oauthlib/oauthlib Source: https://files.pythonhosted.org/packages/source/o/oauthlib/oauthlib-%{version}.tar.gz -# PATCH-FIX-UPSTREAM gh/oauthlib/oauthlib#866 - Make UtilsTests.test_filter_params Python 3.13+ compatible -Patch1: https://github.com/oauthlib/oauthlib/pull/866.patch#/Make-UtilsTests.test_filter_params-Python-3.13-compatible.patch BuildRequires: %{python_module PyJWT >= 2.0.0} BuildRequires: %{python_module blinker >= 1.4} BuildRequires: %{python_module cryptography >= 3.0.0 } +BuildRequires: %{python_module pip} BuildRequires: %{python_module pyasn1} BuildRequires: %{python_module pytest} BuildRequires: %{python_module setuptools} +BuildRequires: %{python_module wheel} BuildRequires: fdupes BuildRequires: python-rpm-macros Requires: python-PyJWT >= 2.0.0 @@ -61,18 +60,12 @@ veneer on top of OAuthLib and get OAuth support for very little effort. %prep %setup -q -n oauthlib-%{version} -%patch -P 1 -p1 %build -%python_build +%pyproject_wheel %install -%python_install -# Fix python-bytecode-inconsistent-mtime -pushd %{buildroot}%{python_sitelib} -find . -name '*.pyc' -exec rm -f '{}' ';' -python%python_bin_suffix -m compileall *.py ';' -popd +%pyproject_install %python_expand %fdupes %{buildroot}%{$python_sitelib} %check @@ -83,9 +76,7 @@ donttest="test_rsa_bad_keys" %files %{python_files} %license LICENSE %doc README.rst CHANGELOG.rst -%dir %{python_sitelib}/oauthlib -%{python_sitelib}/oauthlib/* -%dir %{python_sitelib}/oauthlib-%{version}-py*.egg-info -%{python_sitelib}/oauthlib-%{version}-py*.egg-info/* +%{python_sitelib}/oauthlib +%{python_sitelib}/oauthlib-%{version}.dist-info %changelog