Documentation
The tp_finalize C API doc currently uses the older PyErr_Fetch + PyErr_Restore API to stash the current exception in its sample implementation. That API was deprecated in 3.12.
Update the example to use the suggested replacement PyErr_GetRaisedException and PyErr_SetRaisedException
Linked PRs