This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author gvanrossum
Recipients asvetlov, gvanrossum, iritkatriel, jinty, r.david.murray, vstinner, yselivanov
Date 2022-03-20.16:39:17
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1647794357.47.0.160774371835.issue25489@roundup.psfhosted.org>
In-reply-to
Content
With python built from main I get:

/Users/guido/test_sys_exit_in_exception_handler.py:12: DeprecationWarning: There is no current event loop
  loop = asyncio.get_event_loop()
Got error, exiting
Exception ignored in: <bound method BaseEventLoop.call_exception_handler of <_UnixSelectorEventLoop running=True closed=False debug=False>>
Traceback (most recent call last):
  File "/Users/guido/cpython/Lib/asyncio/base_events.py", line 1749, in call_exception_handler
    self._exception_handler(self, context)
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/guido/test_sys_exit_in_exception_handler.py", line 6, in handler
    sys.exit(42)
    ^^^^^^^^^^^^
SystemExit: 42


This is printed from write_unraisable_exc_file(). Earlier comments in this issue indicate that the exception is being raised from a finalizer (__del__ method). But how?
History
Date User Action Args
2022-03-20 16:39:17gvanrossumsetrecipients: + gvanrossum, vstinner, r.david.murray, asvetlov, yselivanov, jinty, iritkatriel
2022-03-20 16:39:17gvanrossumsetmessageid: <1647794357.47.0.160774371835.issue25489@roundup.psfhosted.org>
2022-03-20 16:39:17gvanrossumlinkissue25489 messages
2022-03-20 16:39:17gvanrossumcreate