Description of problem: The `python3` REPL in Fedora 37 currently shows a traceback on issuing the command `help("invalid query")`, this is a regression from 3.10, caused by upstream commit 8868d48712aee2b490efaf60bed8dfe9fb14d6b7, and was subsequently fixed (in 3.11) via upstream commit e2af980e19794adb36647396c74a7e5aa96ba90e. Version-Release number of selected component (if applicable): python3-3.11.0-1.fc37.x86_64 How reproducible: 100% Steps to Reproduce: 1. run `python3` 2. At the >>> prompt, type `help("foobar")` Actual results: >>> help("foobar") Traceback (most recent call last): File "<stdin>", line 1, in <module> File "<frozen _sitebuiltins>", line 103, in __call__ File "/usr/lib64/python3.11/pydoc.py", line 2001, in __call__ self.help(request) File "/usr/lib64/python3.11/pydoc.py", line 2057, in help elif request: doc(request, 'Help on %s:', output=self._output) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib64/python3.11/pydoc.py", line 1784, in doc pager(render_doc(thing, title, forceload)) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib64/python3.11/pydoc.py", line 1758, in render_doc object, name = resolve(thing, forceload) ^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib64/python3.11/pydoc.py", line 1744, in resolve raise ImportError('''\ ImportError: No Python documentation found for 'foobar'. Use help() to get the interactive help utility. Use help(str) for help on the str class. >>> Expected results: As in 3.10, >>> help("foobar") No Python documentation found for 'foobar'. Use help() to get the interactive help utility. Use help(str) for help on the str class. >>> Additional info: I wanted to submit this as a PR, but after looking at the comments in the spec file, the contents of https://fedoraproject.org/wiki/SIGs/Python/PythonPatches, and the repo https://github.com/fedora-python/cpython, I had to admit to myself that I couldn't figure out how I should do that. Please incorporate commit e2af980e19794adb36647396c74a7e5aa96ba90e into the Fedora python3 package and release new builds to Bodhi for F37, as this issue has already been fixed upstream and makes interactive Python use extremely frustrating.
FEDORA-2022-dbb811d203 has been submitted as an update to Fedora 37. https://bodhi.fedoraproject.org/updates/FEDORA-2022-dbb811d203
> I wanted to submit this as a PR, but after looking at the comments in the spec file, the contents of https://fedoraproject.org/wiki/SIGs/Python/PythonPatches, and the repo https://github.com/fedora-python/cpython, I had to admit to myself that I couldn't figure out how I should do that. Don't worry about that. Adding a patch in whatever way and opening a PR is good enough, somebody from Python Maint would take that and convert it to the form we want. Anyway, this has been included in 3.11.1 so no backport is needed.
FEDORA-2022-dbb811d203 has been pushed to the Fedora 37 stable repository. If problem still persists, please make note of it in this bug report.