mirror of
https://github.com/python/cpython.git
synced 2025-12-31 04:23:37 +00:00
Revert "gh-96844: Improve error message of list.remove (gh-106455)" (#116956)
This reverts commit 217f47d6e5.
This commit is contained in:
parent
2a4cbf17af
commit
f6cdc6b4a1
3 changed files with 5 additions and 5 deletions
|
|
@ -430,10 +430,10 @@ Simple example::
|
|||
>>> [1, 2, 3].remove(42)
|
||||
Traceback (most recent call last):
|
||||
File "<stdin>", line 1, in <module>
|
||||
ValueError: 42 is not in list
|
||||
ValueError: list.remove(x): x not in list
|
||||
|
||||
That doctest succeeds if :exc:`ValueError` is raised, with the ``42 is not in list``
|
||||
detail as shown.
|
||||
That doctest succeeds if :exc:`ValueError` is raised, with the ``list.remove(x):
|
||||
x not in list`` detail as shown.
|
||||
|
||||
The expected output for an exception must start with a traceback header, which
|
||||
may be either of the following two lines, indented the same as the first line of
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue