pytest
pytest copied to clipboard
Set `sys.last_exc` in addition to `last_type`/`last_value`/`last_traceback` on Python>=3.12
Hey @bluetech, I submitted a PR: https://github.com/pytest-dev/pytest/pull/11934
As last_exc is the same as last_value (from trying locally and looking at python here), and have added an if to check we're only using it on Python versions >= 3.12.0. Let me know if I need to do anything else!