Yeah the escape key closes the windows build. It was left in here as we assumed nobody would press it but unfortunately you did :)
On development in general, everything that could happen, will happen. I assumed esc would pause the game if that helps for feedback ;)
I have also encountered this bug . . . as I was tempted to see for myself after reading these comments