Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
tweak docs, remove repetition in test
  • Loading branch information
iritkatriel committed Nov 6, 2023
commit 82c6341a043a807dff6ad03ef938572336185d27
3 changes: 2 additions & 1 deletion Doc/reference/datamodel.rst
Original file line number Diff line number Diff line change
Expand Up @@ -1220,7 +1220,8 @@ Frame objects support one method:
.. versionadded:: 3.4

.. versionchanged:: 3.13
Attempting to clear a suspended frame raises :exc:`RuntimeError`.
Attempting to clear a suspended frame raises :exc:`RuntimeError`
(as has always been the case for executing frames).


.. _traceback-objects:
Expand Down
4 changes: 2 additions & 2 deletions Doc/whatsnew/3.13.rst
Original file line number Diff line number Diff line change
Expand Up @@ -397,8 +397,8 @@ Deprecated
and methods that consider plural forms even if the translation was not found.
(Contributed by Serhiy Storchaka in :gh:`88434`.)

* Calling :meth:`frame.clear` on a suspended frame raises :exc:`RuntimeError`,
as has always been the case for an executing frame.
* Calling :meth:`frame.clear` on a suspended frame raises :exc:`RuntimeError`
(as has always been the case for an executing frame).
(Contributed by Irit Katriel in :gh:`79932`.)


Expand Down
5 changes: 0 additions & 5 deletions Lib/test/test_frame.py
Original file line number Diff line number Diff line change
Expand Up @@ -81,11 +81,6 @@ def g():
next(gen)
self.assertFalse(endly)

# Raise exception when attempting to clear a suspended frame
with self.assertRaisesRegex(RuntimeError, r'suspended frame'):
gen.gi_frame.clear()
self.assertFalse(endly)

# Cannot clear a suspended frame
with self.assertRaisesRegex(RuntimeError, r'suspended frame'):
gen.gi_frame.clear()
Expand Down