you likely have a script running that closes the window on a timer, if you dont think you should have any scripts running at all, then go
ALT-R / file / unload / file / unload etc etc untill there arent any loaded.

If u know u have scripts, then try and find the one thats closing it, maybe search for :TEXT: or :OPEN: