[issue47007] [doc] str docs are inconsistent with special method lookup

2022-03-13 Thread Vanshaj Singhania
Change by Vanshaj Singhania : -- keywords: +patch pull_requests: +29961 stage: -> patch review pull_request: https://github.com/python/cpython/pull/31863 ___ Python tracker <https://bugs.python.org/issu

[issue47007] [doc] str docs are inconsistent with special method lookup

2022-03-13 Thread Vanshaj Singhania
New submission from Vanshaj Singhania : The documentation for the `str` class[^1] says: > If neither encoding nor errors is given, str(object) returns object.__str__() This led our students[^2] to try the following code: >>> class Test: ... def