diff -r e31d5a36d1f3 -r e27d253bd0ba BeremizIDE.py --- a/BeremizIDE.py Mon Aug 28 10:49:53 2017 +0000 +++ b/BeremizIDE.py Fri Sep 08 11:53:48 2017 +0300 @@ -163,9 +163,11 @@ self.TimerAccessLock.release() def _should_write(self): - wx.CallAfter(self._write) + app = wx.GetApp() + if app is not None: + wx.CallAfter(self._write) + if MainThread == currentThread().ident: - app = wx.GetApp() if app is not None: if self.YieldLock.acquire(0): app.Yield()