Martin Panter added the comment: getdoc-news.patch suggests some wording to add to What’s New, and also adds a “Changed in version 3.5” note to inspect.getdoc().
BTW I also noticed that the class doc strings are not inherited from object.__doc__, although method doc strings _are_ inherited from object(), such as object.__init__.__doc__. The current documentation suggests that the class doc string “The most base type” should also be inherited. $ cat module.py class SomeClass: '''CLASS DOCSTRING''' def __init__(self): '''METHOD DOCSTRING''' $ ./python -m pydoc module.SomeClass # Doc strings intact [. . .] module.SomeClass = class SomeClass(builtins.object) | CLASS DOCSTRING | | Methods defined here: | | __init__(self) | METHOD DOCSTRING | [. . .] $ ./python -OOm pydoc module.SomeClass # Method inherited, class stripped [. . .] module.SomeClass = class SomeClass(builtins.object) | Methods defined here: | | __init__(self) | Initialize self. See help(type(self)) for accurate signature. | [. . .] I also wonder how well this feature would work when someone tries to override a base method by using a mix-in type class. ---------- Added file: http://bugs.python.org/file39379/getdoc-news.patch _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue15582> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com