Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Clicking on the console window blocks output #34

Closed
fabio-muramatsu opened this issue Oct 16, 2017 · 2 comments
Closed

Clicking on the console window blocks output #34

fabio-muramatsu opened this issue Oct 16, 2017 · 2 comments

Comments

@fabio-muramatsu
Copy link

Windows version: 10.0.15063

What I'm doing
I've noticed that, if I click anywhere in the console window while a command is running, it seems to be blocked until I press some key to undo the mouse selection. I can reproduce it using the NodeJS REPL:

  1. Open nodejs and type in a command that prints something after an interval, for instance setTimeout(() => console.log("Done"), 2000);
  2. After pressing enter and before the timeout elapses, click somewhere in the console window, selecting a "unit cell" in the console
  3. While this "cell" is selected by this mouse click, the output is not printed to the screen, as if the command has been blocked
  4. If I press a key on the keyboard, the mouse selection is undone, and the output is printed

What should happen
Clicking on the console window should not block the output from programs already running in the console. I have faced this problem with a webserver using Express and with MongoDB. Sometimes, when debugging, I accidentally clicked on the console window, preventing requests to the webserver and database from being processed. Once I press a key to undo the mouse click selection, the request is served. In my case, I was always using stdout (printing logs), so I guess execution is being blocked until the program can write to the console.

This behavior does not happen using Bash on Linux, so I suppose it's not by design. Any help would be appreciated.
Thanks in advance.

@khouzam
Copy link

khouzam commented Oct 16, 2017

Hi @fabio-muramatsu,

This is indeed by design when you have QuickEdit mode selected. If you want to get the behavior that you're looking for, you can turn off QuickEdit and clicking in the window will not block output to the window. One of the reasons behind this behavior is that QuickEdit allows you to quickly select a region of the console to copy the text from, it would be very hard to have that happen if the buffer is scrolling at the same time.

We understand that not everyone wants this behavior, that is why there is the option to change it.

Thanks
~Gilles

@fabio-muramatsu
Copy link
Author

Hi @khouzam.
Thanks for the response. Personally, though, I would prefer that Quick Edit allowed selecting text to copy (which is very useful indeed) without blocking the output, which better aligns the console behavior with bash. But I get your point.
Since this is not a bug, I guess this issue can be closed. Thank you again for your attention.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants