-
-
Notifications
You must be signed in to change notification settings - Fork 474
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Windows: "PyEval_RestoreThread: NULL tstate" in tkinter example #535
Comments
Tkinter example was tested using Tk 8.5 on Windows and Tk 8.6 on Linux. You can try downgrading Tk version and see if the issue reproduces. |
I see the same issue: commenting the call to self.browser_frame.focus_set() in:
solves the problem. |
What about focus issues when you comment that code out? |
Hi Czarek, |
See Issue #255 and in source code comments that reference that issue. See any "focus" calls in the example and make it work similarly in your app. You can also try running with Tk 8.5 which doesn't throw the "NULL tstate" error. |
Thanks a lot, I looked #255 already. Will try to mimic all of the focus calls from your example and report back, once successfull. |
Ok. if found the 2 pieces to make it work, thank you very much!!!
The browser is attached to a tk.Notebook in my application:
This works now smoothly, even with the changes to the focus handler reverted:
|
Can you reproduce the issue with the official example originally reported by ryanalder here in first comment? |
In your original implementation I can. I will make the 2 changes and report back
and
|
It works without steeling focus, however the call in
still needs to be commented out. I am attaching the example script. |
In tkinter 8.5 on Windows when you drag the window during initial loading you can still see the |
The |
tkinter dragging window error Fatal Python error: PyEval_RestoreThread: NULL tstate Current thread 0x00003b14 (most recent call first): Process finished with exit code -1073740791 (0xC0000409) |
Steps to reproduce:
I have tested this on two machines (same software versions). 100% reproducible for me so far. Doesn't matter when during execution this happens, even after using the browser for a while if you repeat steps 3 and 4 it will crash.
The text was updated successfully, but these errors were encountered: