[issue1779233] PyThreadState_SetAsyncExc and the main thread

2009-10-18 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: The following works (2.6 and trunk): import ctypes, thread ctypes.pythonapi.PyThreadState_SetAsyncExc( ctypes.c_long(thread.get_ident()), ctypes.py_object(ZeroDivisionError)) for i in range(1000): pass The thing to remember is that

[issue1779233] PyThreadState_SetAsyncExc and the main thread

2009-10-18 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: I've added a test for it in r75499. Now closing this bug, still the function actually works :-) -- resolution: - works for me status: open - closed ___ Python tracker rep...@bugs.python.org

[issue1779233] PyThreadState_SetAsyncExc and the main thread

2008-07-11 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc [EMAIL PROTECTED] added the comment: Two things may prevent the exception from being seen: - First, the async exception is not immediate; it is checked every 100 bytecodes (=sys.getcheckinterval()). When testing from the interactive prompt, try something like for x in

[issue1779233] PyThreadState_SetAsyncExc and the main thread

2008-05-29 Thread Thomas Heller
Changes by Thomas Heller [EMAIL PROTECTED]: -- assignee: theller - ___ Python tracker [EMAIL PROTECTED] http://bugs.python.org/issue1779233 ___ ___ Python-bugs-list

[issue1779233] PyThreadState_SetAsyncExc and the main thread

2008-01-19 Thread Christian Heimes
Changes by Christian Heimes: -- assignee: - theller nosy: +theller _ Tracker [EMAIL PROTECTED] http://bugs.python.org/issue1779233 _ ___ Python-bugs-list mailing list