STINNER Victor added the comment: On Python 3.4, windll.kernel32.RaiseException(2, 0, 0, None) raised a FileNotFound error.
On Python 3.5, it displays a popup and the program exit. It looks like the behaviour of RaiseException() changed in Python 3.5. I tested in debug and release mode. @Steve: Any idea? -- Instead of RaiseException, you can use ctypes.pythondll.PyErr_SetFromWindowsErr(code). > code = int.from_bytes(b"\xE0msc", "big") Why not writing directly code = 3765269347? The unit test should also check the exception message. ---------- _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue22977> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com