Amazingly, I actually stumbled upon the root cause and the resolution:
When geany "executes" a script, it does so in a popup cmd.exe window. Now close 
geany, whether by crashing it with external monitors (who knows whats happening 
with the split second redrawing) or by simply clicking the "X" to close geany. 
Its child cmd.exe will be left open. This leaves some socket file somewhere 
that triggers the above behavior. Closing all geanys, and closing its child 
cmd.exe, will resolve the issue. I can consistently reproduce it with this 
dummy python script
```import time
while True:
    time.sleep(5)
```
As something to hold the child cmd.exe open.

I don't know why geany sometimes crashes when connecting/disconnecting external 
monitors. It may be something so suble we may never know. But, geany should 
kill its children cmd.exe windows, or if it doesnt want to / cant (I don't know 
the underlying architecture) it should reopen gracefully even with a straggling 
cmd.exe window.

Note any cmd.exes I created myself are unrelated. Only cmd.exes that geany 
created are relevant. Should I create a new bug for this, since we now know its 
not particularly related to external monitors?

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/geany/geany/issues/2555#issuecomment-671383107

Reply via email to