snowkit / atom-haxe

atom.io haxe plugin, includes completion, error checking and more.
MIT License
43 stars 10 forks source link

Find a better way to keep haxe server running when closing/opening windows #59

Open kevinresol opened 8 years ago

kevinresol commented 8 years ago

As titled, atom-haxe tries to start haxe --wait for each atom window which results in Error: Couldn't wait on 127.0.0.1:6112 (can be seen when toggled completion debug log), if there is already a haxe server started by another atom window.

This is not a big deal, because the completion still works. It is just wasting a little CPU.

jeremyfa commented 8 years ago

Yes, that's actually a temporary workaround to prevent the server from not being restarted when working with multiple windows and closing the one that has started the server.

Without this workaround, you could kill the server without knowing it when closing the window (and wonder why completion does not work anymore).

That said we should for sure look for a better way of handling this.

kevinresol commented 8 years ago

arghhh, I see. That make sense.

kevinresol commented 8 years ago

Just a small suggestion, what if check only when a completion is needed?

jeremyfa commented 8 years ago

Yes, that could be an option. Will have to see that after the haxe rewrite is done.