]> git.ipfire.org Git - thirdparty/Python/cpython.git/commit
[3.11] gh-102541: Fix Helper.help("mod") for non-existent mod (GH-105934) (#106323)
authorMiss Islington (bot) <31488909+miss-islington@users.noreply.github.com>
Sat, 1 Jul 2023 23:15:44 +0000 (16:15 -0700)
committerGitHub <noreply@github.com>
Sat, 1 Jul 2023 23:15:44 +0000 (23:15 +0000)
commit9e335860188229a7985fe9a8b72ee62c684aa9eb
tree7584de0c1372d8da2a798431dff1d405bd218401
parentf5e29f424597a970d7cfde3402891259e0e4c1dd
[3.11] gh-102541: Fix Helper.help("mod") for non-existent mod (GH-105934) (#106323)

gh-102541: Fix Helper.help("mod") for non-existent mod (GH-105934)

If the output arg to Helper() is a stream rather than the default None, which means 'page to stdout', the ImportError from pydoc.resolve is currently not caught in pydoc.doc. The same error is caught when output is None.
---------

(cherry picked from commit 0530f4f64629ff97f3feb7524da0833b9535e8b6)

Co-authored-by: Kirill Podoprigora <kirill.bast9@mail.ru>
Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
Lib/pydoc.py
Lib/test/test_pydoc.py
Misc/NEWS.d/next/Library/2023-07-01-16-40-54.gh-issue-102541.C1ahtk.rst [new file with mode: 0644]