]> git.ipfire.org Git - thirdparty/Python/cpython.git/commit
gh-121288: Make error message for index() methods consistent (GH-121395)
authorSerhiy Storchaka <storchaka@gmail.com>
Fri, 5 Jul 2024 17:50:45 +0000 (20:50 +0300)
committerGitHub <noreply@github.com>
Fri, 5 Jul 2024 17:50:45 +0000 (10:50 -0700)
commit8ecb8962e33930dd56d72004a59336d4b00fce22
treeef8fe41c3531215b14aa0e5768d067535aa57ef0
parent0e77540d86833f0a0ef964ab51f35be9bfb533f9
gh-121288: Make error message for index() methods consistent (GH-121395)

Make error message for index() methods consistent

Remove the repr of the searched value (which can be arbitrary large)
from ValueError messages for list.index(), range.index(), deque.index(),
deque.remove() and ShareableList.index().  Make the error messages
consistent with error messages for other index() and remove()
methods.
Lib/multiprocessing/shared_memory.py
Misc/NEWS.d/next/Core and Builtins/2024-07-05-11-29-27.gh-issue-121288.lYKYYP.rst [new file with mode: 0644]
Modules/_collectionsmodule.c
Objects/listobject.c
Objects/rangeobject.c