![]() |
python thread safety: printing from thread to redirected stdout - safe?
This is actually a wxPython GUI question, but may still fall under the generic python umbrella.
If I redirect stdout (which, in my case, will update a wxPython text control), then run a print command from a thread. The thread updates the GUI via print. Is this safe or should I communicate via thread & main & let main handle it? |
I believe it is commonly recommended to never update the GUI through a thread, always the main.
|
Have a look at wxAnyThread which is in the PyPI and looks useful. Note this quoted from the module :
Quote:
|
| All times are GMT -5. The time now is 12:36 PM. |