-
-
Notifications
You must be signed in to change notification settings - Fork 212
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
[Feature request] Allow interruption of execution #237
Comments
Rationale: Without this feature, any infinite loop cannot be stopped without entirely quitting and restarting VSCode, losing context, etc. To continue working it is necessary not only to be able to regain control of the REPL but also to terminate execution of the process so that it doesn't consume CPU cycles, drain batteries, etc. This can be necessary both for accidental infinite loops and for intentional very-long-running processes that the developer realizes aren't doing what was intended, and have to be stopped and restarted after editing code. |
@PEZ Isn't this now in the current version of Calva? |
Indeed it is. Thanks to @cfehse ! |
How? I just started an infinite loop and don't see any way to interrupt it. |
It would be great if whatever actually does work would be easily discoverable. Ideally the same method for interrupting a running evaluation would also work no matter how/where one started it. |
@lspector Can you provide detailed reproduction steps (commands used, whether in editor or in REPL, etc)? That would be very helpful and much appreciated. |
@bpinge:
|
Yes that form creates intermediately 100% CPU utilization - so that nearly no keystroke gets through the message loop and the REPL window is constantly updating the output. Under this conditions no instantaneously interruption of the evaluations can be expected. If you are a bit patient and either close the REPL window (which will interrupt a running evaluation as well) or wait for the editor context menu or the command prompt to appear and then select there the Try something less "brutal" like |
Thanks! This does work with the
However, In any event, I agree this is a pretty good solution, once one knows about the interrupt command. I don't know if there's a way to make that more discoverable. |
@lspector
That's a general Problem with all the keyboard shortcuts I think. We introduced the editor context menu to get an idea, which commands are available and in the REPL window there is a list with important command in the intro section. This may be easily be overlooked. Anyway I will close this issue for now. Thanks for your testing! |
Interrupting execution of a long-running (possibly infinite) is a very desirable feature that I would love to have in Calva.
Shooting for the moon here, but if execution could be interrupted and information about the context of interruption printed (ideally the call stack and super super desirably the values of locals in each stack frame), then that would be truly fabulous.
The text was updated successfully, but these errors were encountered: