pyo3/guide
Adam Reichold 4dc6c1643e Turn calls of __traverse__ into no-ops for unsendable pyclass if on the wrong thread
Adds a "threadsafe" variant of `PyCell::try_borrow` which will fail instead of
panicking if called on the wrong thread and use it in `call_traverse` to turn GC
traversals of unsendable pyclasses into no-ops if on the wrong thread.

This can imply leaking the underlying resource if the originator thread has
already exited so that the GC will never run there again, but it does avoid hard
aborts as we cannot raise an exception from within `call_traverse`.
2023-12-23 15:01:08 +01:00
..
src Merge pull request #3661 from PyO3/iter-output-type 2023-12-20 12:53:42 +00:00
book.toml guide: Add `playground.runnable` = false to book.toml 2023-09-05 22:28:43 +02:00
pyclass_parameters.md Turn calls of __traverse__ into no-ops for unsendable pyclass if on the wrong thread 2023-12-23 15:01:08 +01:00
pyo3_version.py release: 0.17.2 2022-10-04 08:13:53 +01:00