Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
gh-142349: Add help("lazy") support (GH-149886)
(cherry picked from commit 8be3fb1)

Co-authored-by: sobolevn <mail@sobolevn.me>
  • Loading branch information
sobolevn authored and miss-islington committed May 15, 2026
commit 3e0793ff85ff185ef635e90c53526ab1a9187fde
1 change: 1 addition & 0 deletions Doc/tools/extensions/pydoc_topics.py
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,7 @@
"in",
"integers",
"lambda",
"lazy",
"lists",
"naming",
"nonlocal",
Expand Down
1 change: 1 addition & 0 deletions Lib/pydoc.py
Original file line number Diff line number Diff line change
Expand Up @@ -1845,6 +1845,7 @@ class Helper:
'in': ('in', 'SEQUENCEMETHODS'),
'is': 'COMPARISON',
'lambda': ('lambda', 'FUNCTIONS'),
'lazy': ('lazy', 'MODULES'),
'nonlocal': ('nonlocal', 'global NAMESPACES'),
'not': 'BOOLEAN',
'or': 'BOOLEAN',
Expand Down
2 changes: 1 addition & 1 deletion Lib/test/test_pydoc/test_pydoc.py
Original file line number Diff line number Diff line change
Expand Up @@ -2172,7 +2172,7 @@ def mock_getline(prompt):

def test_keywords(self):
self.assertEqual(sorted(pydoc.Helper.keywords),
sorted(keyword.kwlist))
sorted(keyword.kwlist + ['lazy']))

def test_interact_empty_line_continues(self):
# gh-138568: test pressing Enter without input should continue in help session
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Add :keyword:`lazy` to the list of support topic by :func:`help`.
Loading