public inbox for git-commits@fedoraproject.org
help / color / mirror / Atom feed
From: releng-bot <releng-bot@fedoraproject.org>
To: git-commits@fedoraproject.org
Subject: [rpms/python-pydocstyle] rawhide: Unretirement request: https://forge.fedoraproject.org/releng/fedora-scm-requests/issues/1730
Date: Thu, 05 Nov 2026 00:21:47 GMT	[thread overview]
Message-ID: <179383810736.1.17452855307792029128.rpms-python-pydocstyle-d7e757dafdcf@fedoraproject.org> (raw)

A new commit has been pushed.

Repo   : rpms/python-pydocstyle
Branch : rawhide
Commit : d7e757dafdcf3e6aeb3dbed7286251026ee9796d
Author : releng-bot <releng-bot@fedoraproject.org>
Date   : 2026-11-05T00:21:43+00:00
Stats  : +339/-1 in 8 file(s)
URL    : https://src.fedoraproject.org/rpms/python-pydocstyle/c/d7e757dafdcf3e6aeb3dbed7286251026ee9796d?branch=rawhide

Log:
Unretirement request: https://forge.fedoraproject.org/releng/fedora-scm-requests/issues/1730

---
diff --git a/.git-blame-ignore-revs b/.git-blame-ignore-revs
new file mode 100644
index 0000000..3e8b57b
--- /dev/null
+++ b/.git-blame-ignore-revs
@@ -0,0 +1,2 @@
+# Align blocks in spec file
+575e5e248aa82c2bf086356504330d6b50a15c2b

diff --git a/.gitignore b/.gitignore
new file mode 100644
index 0000000..d3d6a29
--- /dev/null
+++ b/.gitignore
@@ -0,0 +1,6 @@
+/pydocstyle-2.0.0.tar.gz
+/pydocstyle-4.0.1.tar.gz
+/pydocstyle-5.0.1.tar.gz
+/pydocstyle-5.0.2.tar.gz
+/pydocstyle-6.0.0.tar.gz
+/pydocstyle-6.3.0.tar.gz

diff --git a/656.patch b/656.patch
new file mode 100644
index 0000000..48404b6
--- /dev/null
+++ b/656.patch
@@ -0,0 +1,109 @@
+From 306c7c8f2d863bdc098a65d2dadbd4703b9b16d5 Mon Sep 17 00:00:00 2001
+From: Alfred Wingate <parona@protonmail.com>
+Date: Wed, 1 Nov 2023 11:12:08 +0200
+Subject: [PATCH] Add support for PEP701
+
+* fstrings are broken into several distinct tokens in py3.12, reattach
+  them together as a singular string to preserve previous behavior.
+
+Closes: https://github.com/PyCQA/pydocstyle/issues/646
+Signed-off-by: Alfred Wingate <parona@protonmail.com>
+---
+ docs/release_notes.rst   |  8 ++++++++
+ src/pydocstyle/parser.py | 23 +++++++++++++++++++++++
+ src/tests/parser_test.py | 29 +++++++++++++++++++++++++++++
+ 3 files changed, 60 insertions(+)
+
+diff --git a/docs/release_notes.rst b/docs/release_notes.rst
+index 46e36562..3db4c189 100644
+--- a/docs/release_notes.rst
++++ b/docs/release_notes.rst
+@@ -4,6 +4,14 @@ Release Notes
+ **pydocstyle** version numbers follow the
+ `Semantic Versioning <http://semver.org/>`_ specification.
+ 
++
++Current development version
++---------------------------
++
++Bug Fixes
++
++* Add support for PEP-701 fixing fstring parsing in python3.12 (#656).
++
+ 6.3.0 - January 17th, 2023
+ --------------------------
+ 
+diff --git a/src/pydocstyle/parser.py b/src/pydocstyle/parser.py
+index 95bd0a10..875f769d 100644
+--- a/src/pydocstyle/parser.py
++++ b/src/pydocstyle/parser.py
+@@ -479,6 +479,29 @@ def parse_docstring(self):
+             )
+             self.stream.move()
+             return docstring
++        if (sys.version_info.major, sys.version_info.minor) >= (
++            3,
++            12,
++        ) and self.current.kind == tk.FSTRING_START:
++
++            def fstring(string):
++                """Recursively parse fstring tokens to output it as one string."""
++                while self.current.kind != tk.FSTRING_END:
++                    self.stream.move()
++                    string += self.current.value
++                    if self.current.kind == tk.FSTRING_START:
++                        string = fstring(string)
++                        self.stream.move()
++                        string += self.current.value
++                return string
++
++            # Reattach fstring tokens together into a string to deal with PEP 701 in python3.12
++            start = self.current.start[0]
++            string = fstring(self.current.value)
++            end = self.current.end[0]
++            docstring = Docstring(string, start, end)
++            self.stream.move()
++            return docstring
+         return None
+ 
+     def parse_decorators(self):
+diff --git a/src/tests/parser_test.py b/src/tests/parser_test.py
+index 582c6cde..2c0bbaca 100644
+--- a/src/tests/parser_test.py
++++ b/src/tests/parser_test.py
+@@ -114,6 +114,35 @@ def do_something(pos_param0, pos_param1, kw_param0="default"):
+     assert str(function) == 'in public function `do_something`'
+ 
+ 
++def test_nested_fstring():
++    """Test parsing fstring with nested fstrings."""
++    parser = Parser()
++    code = CodeSnippet("""\
++        def do_something(pos_param0, pos_param1, kw_param0="default"):
++            f\"""Do something. {f"This is a nested fstring."}\"""
++            return None
++    """)
++    module = parser.parse(code, 'file_path')
++    assert module.is_public
++    assert module.dunder_all is None
++
++    function, = module.children
++    assert function.name == 'do_something'
++    assert function.decorators == []
++    assert function.children == []
++    assert function.docstring == 'f"""Do something. {f"This is a nested fstring."}"""'
++    assert function.docstring.start == 2
++    assert function.docstring.end == 2
++    assert function.kind == 'function'
++    assert function.parent == module
++    assert function.start == 1
++    assert function.end == 3
++    assert function.error_lineno == 2
++    assert function.source == code.getvalue()
++    assert function.is_public
++    assert str(function) == 'in public function `do_something`'
++
++
+ def test_decorated_function():
+     """Test parsing of a simple function with a decorator."""
+     parser = Parser()

diff --git a/changelog b/changelog
new file mode 100644
index 0000000..45d01f2
--- /dev/null
+++ b/changelog
@@ -0,0 +1,126 @@
+* Fri Jan 26 2024 Fedora Release Engineering <releng@fedoraproject.org> - 6.3.0-6
+- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild
+
+* Mon Jan 22 2024 Fedora Release Engineering <releng@fedoraproject.org> - 6.3.0-5
+- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild
+
+* Mon Sep 18 2023 Tadej Janež <tadej.j@nez.si> - 6.3.0-4
+- Temporarily disable tests failing with Python 3.12
+
+* Fri Jul 21 2023 Fedora Release Engineering <releng@fedoraproject.org> - 6.3.0-3
+- Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild
+
+* Thu Jun 15 2023 Python Maint <python-maint@redhat.com> - 6.3.0-2
+- Rebuilt for Python 3.12
+
+* Fri May 19 2023 Tadej Janež <tadej.j@nez.si> - 6.3.0-1
+- Update to 6.3.0 release
+- Use %%{url} in %%{Source0} to avoid redundance
+- Introduce %%_description to avoid %%description duplication
+- Use the new automatic build-time dependency generator
+- Use new %%{pyproject_*} macros
+- Explain why tests are not run via Tox
+- Manually set the correct project version in pyproject.toml
+- Move incorrect shebang removal from %%build to %%prep
+
+* Fri Jan 20 2023 Fedora Release Engineering <releng@fedoraproject.org> - 6.0.0-7
+- Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild
+
+* Fri Jul 22 2022 Fedora Release Engineering <releng@fedoraproject.org> - 6.0.0-6
+- Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild
+
+* Mon Jun 13 2022 Python Maint <python-maint@redhat.com> - 6.0.0-5
+- Rebuilt for Python 3.11
+
+* Fri Jan 21 2022 Fedora Release Engineering <releng@fedoraproject.org> - 6.0.0-4
+- Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild
+
+* Fri Jul 23 2021 Fedora Release Engineering <releng@fedoraproject.org> - 6.0.0-3
+- Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild
+
+* Fri Jun 04 2021 Python Maint <python-maint@redhat.com> - 6.0.0-2
+- Rebuilt for Python 3.10
+
+* Thu Mar 25 2021 Tadej Janež <tadej.j@nez.si> - 6.0.0-1
+- Update to 6.0.0 release
+- Remove obsolete %%python_provide macro
+- Use %%pytest macro
+
+* Wed Jan 27 2021 Fedora Release Engineering <releng@fedoraproject.org> - 5.0.2-4
+- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
+
+* Wed Jul 29 2020 Fedora Release Engineering <releng@fedoraproject.org> - 5.0.2-3
+- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild
+
+* Thu Jul 09 2020 Tadej Janež <tadej.j@nez.si> - 5.0.2-2
+- Replace Python version glob with macro to support Python 3.10
+- Use automatic Requires generation
+
+* Fri Jun 26 2020 Tadej Janež <tadej.j@nez.si> - 5.0.2-1
+- Update to 5.0.2 release
+- Add explicit BuildRequires on python3-setuptools
+
+* Tue May 26 2020 Miro Hrončok <mhroncok@redhat.com> - 5.0.1-3
+- Rebuilt for Python 3.9
+
+* Thu Jan 30 2020 Fedora Release Engineering <releng@fedoraproject.org> - 5.0.1-2
+- Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild
+
+* Wed Dec 11 2019 Tadej Janež <tadej.j@nez.si> - 5.0.1-1
+- Update to 5.0.1 release
+- Clean-up and modernize the SPEC file
+- Drop obsolete Requires/BuildRequires
+
+* Thu Sep 26 2019 Tadej Janež <tadej.j@nez.si> - 4.0.1-2
+- Update %%check section
+- Skip linting with pep8 and drop python3-pytest-pep8 build requirement
+
+* Tue Aug 27 2019 Tadej Janež <tadej.j@nez.si> - 4.0.1-1
+- Update to 4.0.1 release
+
+* Mon Aug 19 2019 Miro Hrončok <mhroncok@redhat.com> - 2.0.0-10
+- Rebuilt for Python 3.8
+
+* Fri Jul 26 2019 Fedora Release Engineering <releng@fedoraproject.org> - 2.0.0-9
+- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild
+
+* Sat Feb 02 2019 Fedora Release Engineering <releng@fedoraproject.org> - 2.0.0-8
+- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild
+
+* Thu Oct 11 2018 Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> - 2.0.0-7
+- Python2 binary package has been removed
+  See https://fedoraproject.org/wiki/Changes/Mass_Python_2_Package_Removal
+
+* Sat Jul 14 2018 Fedora Release Engineering <releng@fedoraproject.org> - 2.0.0-6
+- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
+
+* Tue Jun 19 2018 Miro Hrončok <mhroncok@redhat.com> - 2.0.0-5
+- Rebuilt for Python 3.7
+
+* Fri Feb 09 2018 Iryna Shcherbina <ishcherb@redhat.com> - 2.0.0-4
+- Update Python 2 dependency declarations to new packaging standards
+  (See https://fedoraproject.org/wiki/FinalizingFedoraSwitchtoPython3)
+
+* Fri Feb 09 2018 Fedora Release Engineering <releng@fedoraproject.org> - 2.0.0-3
+- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
+
+* Thu Jul 27 2017 Fedora Release Engineering <releng@fedoraproject.org> - 2.0.0-2
+- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild
+
+* Fri Jun 30 2017 Tadej Janež <tadej.j@nez.si> - 2.0.0-1
+- Initial release in Fedora 25+.
+
+* Mon May 08 2017 Tadej Janež <tadej.j@nez.si> - 2.0.0-0.1
+- Update to 2.0.0 release.
+- Update Requires and BuildRequires for the new version.
+- Drop pep257 compatibility console script.
+
+* Fri Apr 07 2017 Tadej Janež <tadej.j@nez.si> - 1.1.1-0.2
+- Temporarily use GitHub arhive download service until upstream includes tests
+  in the release tarballs.
+- Run tests in %%check.
+- Add appropriate BuildRequires for running the tests.
+- Remove end-of-line encoding fixes which are no longer necessary.
+
+* Mon Jan 02 2017 Tadej Janež <tadej.j@nez.si> - 1.1.1-0.1
+- Initial package.

diff --git a/dead.package b/dead.package
deleted file mode 100644
index 5204a84..0000000
--- a/dead.package
+++ /dev/null
@@ -1 +0,0 @@
-Orphaned for 6+ weeks

diff --git a/pydocstyle-py3.14.patch b/pydocstyle-py3.14.patch
new file mode 100644
index 0000000..96444df
--- /dev/null
+++ b/pydocstyle-py3.14.patch
@@ -0,0 +1,12 @@
+diff -rupN pydocstyle-6.3.0/src/tests/test_integration.py pydocstyle-6.3.0-new/src/tests/test_integration.py
+--- pydocstyle-6.3.0/src/tests/test_integration.py	2023-01-17 21:27:44.000000000 +0100
++++ pydocstyle-6.3.0-new/src/tests/test_integration.py	2025-06-13 16:55:57.924146186 +0200
+@@ -814,7 +814,7 @@ def test_overload_nested_function_valid(
+         from typing import overload
+ 
+         def function_with_nesting():
+-            """Adding a docstring to a function."""
++            """Add a docstring to a function."""
+             @overload
+             def overloaded_func(a: int) -> str:
+                 ...

diff --git a/python-pydocstyle.spec b/python-pydocstyle.spec
new file mode 100644
index 0000000..aade86e
--- /dev/null
+++ b/python-pydocstyle.spec
@@ -0,0 +1,83 @@
+%global pypi_name pydocstyle
+
+Name:       python-%{pypi_name}
+Version:    6.3.0
+Release:    %autorelease
+Summary:    Python docstring style checker
+
+# SPDX
+License:    MIT
+URL:        https://github.com/PyCQA/pydocstyle/
+Source:     %{pypi_source %{pypi_name}}
+Patch:      https://github.com/PyCQA/pydocstyle/pull/656.patch
+# Fix python3.14 test failure
+# (D401: First line should be in imperative mood (perhaps 'Add', not 'Adding')
+# NOTE: Upstream has archived the repository and it is not possible to submit PRs anymore
+Patch:      pydocstyle-py3.14.patch
+
+BuildArch:      noarch
+BuildRequires:  python3-devel
+BuildRequires:  python3dist(pytest)
+
+%global _description %{expand:
+A static analysis tool for checking compliance with Python docstring
+conventions.
+
+It supports most of PEP 257 out of the box, but it should not be considered a
+reference implementation.}
+
+%description %_description
+
+
+%package -n python3-%{pypi_name}
+Summary:    %{summary}
+
+%description -n python3-%{pypi_name} %_description
+
+
+%prep
+%autosetup -n %{pypi_name}-%{version} -p1
+
+# Manually set the correct project version. Upstream does it dynamically when
+# building a release with GitHub Actions by executing:
+# 'poetry version ${{ github.event.release.tag_name }}'.
+sed -r -i 's/(version = ")0.0.0-dev/\1%{version}/' pyproject.toml
+
+# Remove (incorrect) Python shebang from package's __main__.py file.
+sed -i '\|/usr/bin/env|d' src/pydocstyle/__main__.py
+
+
+%generate_buildrequires
+%pyproject_buildrequires
+
+
+%build
+%pyproject_wheel
+
+
+%install
+%pyproject_install
+%pyproject_save_files -L %{pypi_name}
+
+
+%check
+# Disable "install_package" fixure for integration tests since we want the
+# tests to be run against the system-installed version of the package.
+sed -i '/pytestmark = pytest.mark.usefixtures("install_package")/d' \
+    src/tests/test_integration.py
+# Replace 'python(2|3)?' with '%%{__python3}' in tests that run pydocstyle as
+# a named Python module.
+sed -E -i 's|"python(2\|3)?( -m pydocstyle)|"%{__python3}\2|' \
+    src/tests/test_integration.py
+
+%pytest -v src/tests
+
+
+%files -n python3-%{pypi_name} -f %{pyproject_files}
+%doc README.rst
+%license LICENSE-MIT
+%{_bindir}/pydocstyle
+
+
+%changelog
+%autochangelog

diff --git a/sources b/sources
new file mode 100644
index 0000000..3b46387
--- /dev/null
+++ b/sources
@@ -0,0 +1 @@
+SHA512 (pydocstyle-6.3.0.tar.gz) = f8473b19ab6ef0b61787875558f9dd6f9f7f1954e1baa0010942af6d4de8dbca30c8c08be6acbf24aadd1c0a601ba9467b747026a6cd22379f0c4b84a38b57c7

                 reply	other threads:[~2026-11-05  0:21 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=179383810736.1.17452855307792029128.rpms-python-pydocstyle-d7e757dafdcf@fedoraproject.org \
    --to=releng-bot@fedoraproject.org \
    --cc=git-commits@fedoraproject.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox