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

"Rewind" in debugger #2052

Closed
nbros opened this issue Oct 15, 2019 · 2 comments · Fixed by #2117
Closed

"Rewind" in debugger #2052

nbros opened this issue Oct 15, 2019 · 2 comments · Fixed by #2117
Labels
in debugger Relates to the debug adapter or process of launching a debug session is enhancement
Milestone

Comments

@nbros
Copy link

nbros commented Oct 15, 2019

The Dart debugger has a "rewind" feature that allows moving back the execution to the beginning of the current frame (or another frame on the call stack, given a count parameter).

But currently this feature seems impossible to use with Dart Code: when I right-click a stack frame all I see is "Copy Call Stack". I also tried typing "rewind" in the debugger view, and I got "Getter not found: rewind". And when we open the Dart DevTools from Dart Code, the Debugger tab is disabled so we can't enter the rewind command there either.

This is a feature request to add the "Rewind" feature in Dart Code in the context menu of a selected stack frame in the Call Stack view (in the Debug sidebar).
A Debug: Rewind command that can be bound to a key combination would be nice too (for quickly rewinding the current frame with a keystroke).

see also: dart-lang/sdk#38852
and: https://github.com/dart-lang/sdk/blob/master/runtime/observatory/lib/src/elements/debugger.dart#L418

@DanTup DanTup added this to the On Deck milestone Oct 15, 2019
@DanTup DanTup added in debugger Relates to the debug adapter or process of launching a debug session is enhancement labels Oct 15, 2019
@DanTup
Copy link
Member

DanTup commented Oct 15, 2019

Thanks for the issue! VS Code has a concept of "Step back" - I wonder if these match up. I did look for an equiv in Dart a while back, but somehow didn't come across Rewind. I'll do some digging to see what would be involved in supporting it.

@DanTup DanTup modified the milestones: On Deck, v3.7.0 Oct 24, 2019
@DanTup
Copy link
Member

DanTup commented Nov 20, 2019

This is easy enough to implement, but VS Code has bundled two features ("StepBack" and "ReverseContinue") under one flag, which means to enable this we end up with a broken button that says "Reverse" on the toolbar :(

I've opened microsoft/vscode#85215 to see if these can be separated. For now I will ship this being an opt-in flag so you can have it if you want it, but most users won't get this confusing extra broken button.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
in debugger Relates to the debug adapter or process of launching a debug session is enhancement
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants