diff --git a/python-ruamel.std.pathlib.changes b/python-ruamel.std.pathlib.changes index 9cd2988..b0f1ce8 100644 --- a/python-ruamel.std.pathlib.changes +++ b/python-ruamel.std.pathlib.changes @@ -1,3 +1,11 @@ +------------------------------------------------------------------- +Tue Dec 9 04:16:44 UTC 2025 - Steve Kowalik + +- Update to 0.13.0: + * No upstream changelog. +- Add patch support-python314.patch: + * Support Python 3.14 ast changes. + ------------------------------------------------------------------- Thu Mar 27 03:44:15 UTC 2025 - Steve Kowalik diff --git a/python-ruamel.std.pathlib.spec b/python-ruamel.std.pathlib.spec index d574606..9b89b3d 100644 --- a/python-ruamel.std.pathlib.spec +++ b/python-ruamel.std.pathlib.spec @@ -1,7 +1,7 @@ # # spec file for package python-ruamel.std.pathlib # -# Copyright (c) 2025 SUSE LLC +# Copyright (c) 2025 SUSE LLC and contributors # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -17,12 +17,14 @@ Name: python-ruamel.std.pathlib -Version: 0.12.0 +Version: 0.13.0 Release: 0 Summary: Improvements over the standard pathlib module and pathlib2 package License: MIT URL: https://sourceforge.net/projects/ruamel-std-pathlib/ Source: https://files.pythonhosted.org/packages/source/r/ruamel.std.pathlib/ruamel.std.pathlib-%{version}.tar.gz +# PATCH-FIX-OPENSUSE Support Python 3.14 ast changes +Patch0: support-python314.patch BuildRequires: %{python_module orjson} BuildRequires: %{python_module pip} BuildRequires: %{python_module setuptools} @@ -38,7 +40,7 @@ BuildArch: noarch Improvements over the standard pathlib module and pathlib2 package. %prep -%setup -q -n ruamel.std.pathlib-%{version} +%autosetup -p1 -n ruamel.std.pathlib-%{version} %build %pyproject_wheel @@ -49,12 +51,11 @@ export RUAMEL_NO_PIP_INSTALL_CHECK=1 %python_expand %fdupes %{buildroot}%{$python_sitelib} %files %{python_files} -%doc README.rst +%doc README.md %license LICENSE %dir %{python_sitelib}/ruamel %dir %{python_sitelib}/ruamel/std %{python_sitelib}/ruamel/std/pathlib -%{python_sitelib}/ruamel.std.pathlib-%{version}-py3*-nspkg.pth %{python_sitelib}/ruamel_std_pathlib-%{version}.dist-info %changelog diff --git a/ruamel.std.pathlib-0.12.0.tar.gz b/ruamel.std.pathlib-0.12.0.tar.gz deleted file mode 100644 index ea2584f..0000000 --- a/ruamel.std.pathlib-0.12.0.tar.gz +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:6489bb40856d458fc5c3e7ffee454044c5f4db5be3c6fbd8520066436e0af3bd -size 24343 diff --git a/ruamel.std.pathlib-0.13.0.tar.gz b/ruamel.std.pathlib-0.13.0.tar.gz new file mode 100644 index 0000000..ac748bb --- /dev/null +++ b/ruamel.std.pathlib-0.13.0.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1387e81655999851241b07f68569901ba4d502804094cde3c327b849ae702bb8 +size 25509 diff --git a/support-python314.patch b/support-python314.patch new file mode 100644 index 0000000..143a06c --- /dev/null +++ b/support-python314.patch @@ -0,0 +1,39 @@ +Index: ruamel.std.pathlib-0.13.0/setup.py +=================================================================== +--- ruamel.std.pathlib-0.13.0.orig/setup.py ++++ ruamel.std.pathlib-0.13.0/setup.py +@@ -76,7 +76,7 @@ else: + print(*args, **kw1) + + if sys.version_info >= (3, 8): +- from ast import Str, Num, Bytes, NameConstant # NOQA ++ from ast import Constant # NOQA + + + def literal_eval(node_or_string): +@@ -98,15 +98,7 @@ def literal_eval(node_or_string): + raise TypeError('only string or AST nodes supported') + + def _convert(node): +- if isinstance(node, Str): +- if sys.version_info < (3,) and not isinstance(node.s, unicode): +- return node.s.decode('utf-8') +- return node.s +- elif isinstance(node, Bytes): +- return node.s +- elif isinstance(node, Num): +- return node.n +- elif isinstance(node, Tuple): ++ if isinstance(node, Tuple): + return tuple(map(_convert, node.elts)) + elif isinstance(node, List): + return list(map(_convert, node.elts)) +@@ -114,7 +106,7 @@ def literal_eval(node_or_string): + return set(map(_convert, node.elts)) + elif isinstance(node, Dict): + return {_convert(k): _convert(v) for k, v in zip(node.keys, node.values)} +- elif isinstance(node, NameConstant): ++ elif isinstance(node, Constant): + return node.value + elif sys.version_info < (3, 4) and isinstance(node, Name): + if node.id in _safe_names: