]> git.ipfire.org Git - thirdparty/Python/cpython.git/commit
gh-78465: Fix error message for cls.__new__(cls, ...) where cls is not instantiable...
authorSerhiy Storchaka <storchaka@gmail.com>
Fri, 27 Jun 2025 11:35:55 +0000 (14:35 +0300)
committerGitHub <noreply@github.com>
Fri, 27 Jun 2025 11:35:55 +0000 (14:35 +0300)
commitc45f4f3ebe34529a8db3a7918e8dd2e9f7ce8e86
treeac587c1da8ea3a4521d0d13719968b88e3e31d28
parentf3aec60d7a01c5f085a3ef2d6670d46b42b8ddd3
gh-78465: Fix error message for cls.__new__(cls, ...) where cls is not instantiable (GH-135981)

Previous error message suggested to use cls.__new__(), which
obviously does not work. Now the error message is the same as for
cls(...).
Lib/test/support/__init__.py
Lib/test/test_sys.py
Lib/test/test_types.py
Misc/NEWS.d/next/Core_and_Builtins/2025-06-26-15-25-51.gh-issue-78465.MbDN8X.rst [new file with mode: 0644]
Objects/typeobject.c