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

Debugger does not show column indicator when stopped at a breakpoint #616

Closed
grumpkin opened this issue Mar 24, 2017 · 5 comments
Closed
Labels
Milestone

Comments

@grumpkin
Copy link

System Details

  • Operating system name and version: Windows 10 - 1607
  • VS Code version: 1.9.1
  • PowerShell extension version: 0.11.0
  • Output from $PSVersionTable:
    PSVersion 5.1.14393.953
    PSEdition Desktop
    PSCompatibleVersions {1.0, 2.0, 3.0, 4.0...}
    BuildVersion 10.0.14393.953
    CLRVersion 4.0.30319.42000
    WSManStackVersion 3.0
    PSRemotingProtocolVersion 2.3
    SerializationVersion 1.1.0.1
Copy / paste the below commands into the PowerShell Integrated Terminal, and paste the output here

code -v
 - 1.9.1
f9d0c687ff2ea7aabd85fb9a43129117c0ecf519

$pseditor.EditorServicesVersion
Major  Minor  Build  Revision
-----  -----  -----  --------
0      11     0      0

code --list-extensions --show-versions
be5invis.vscode-icontheme-nomo-dark@1.2.5
ms-vscode.PowerShell@0.11.0

$PSVersionTable
Name                           Value
----                           -----
PSVersion                      5.1.14393.953
PSEdition                      Desktop
PSCompatibleVersions           {1.0, 2.0, 3.0, 4.0...}
BuildVersion                   10.0.14393.953
CLRVersion                     4.0.30319.42000
WSManStackVersion              3.0
PSRemotingProtocolVersion      2.3
SerializationVersion           1.1.0.1

Issue Description

In a statement that has multiple commands, for instance a string where you're referencing a variable property or a foreach statement can we highlight the actual statement being executed. ISE does this so in a statement such as $UpdateValue = "User moved to $($Matches['ou']) by $($Object.MovedByName) on $($Object.MovedOn)" ISE will highlight each of those statements to show what it's actually executing, right now in Code it just highlights the entire line and appears to execute it three times

@daviwil
Copy link
Contributor

daviwil commented Mar 24, 2017

Can you give me a screenshot of what you see in the ISE that you expect to see in VS Code? I'm not sure how the ISE is highlighting each statement separately.

@grumpkin
Copy link
Author

If I run the code in the screenshots, when it hits line 11, it initially highlights the entire line, if I then step through that line with F10 it highlights each statement that it's evaluating.

dbg_step_1
dbg_step_2
dbg_step_3

@daviwil
Copy link
Contributor

daviwil commented Mar 24, 2017

Thank you! I wasn't aware you were referring to the debugger. VS Code now has a way to indicate in-line where the debugger has stopped in these cases but it looks like we didn't implement this correctly. Thanks for catching the bug, I'll get it fixed for the next patch update.

@daviwil daviwil added Issue-Bug A bug to squash. Area-Debugging labels Mar 24, 2017
@daviwil daviwil added this to the Next Patch Update milestone Mar 24, 2017
@daviwil daviwil changed the title In statement with multiple commands highlight the command being executed Debugger does not show column indicator when stopped at a breakpoint Mar 24, 2017
@grumpkin
Copy link
Author

Apologies, I really wasn't very clear in the initial description.

That's awesome, looking forward to the next update.

@daviwil
Copy link
Contributor

daviwil commented Mar 24, 2017

Here's what it looks like in VS Code's way:

image

The yellow arrow indicator shows the column number where the breakpoint is hit. Doesn't seem like they select the actual region that I'm returning but maybe they'll change that in the future.

daviwil added a commit to daviwil/PowerShellEditorServices that referenced this issue Mar 24, 2017
This change causes the column number of the debugger's currently stopped
position to be passed through with the top stack frame.  This allows VS
Code's debugger UI to show an indicator that points to where the debugger
stopped when stepping through code.

Resolve PowerShell/vscode-powershell#616
daviwil added a commit to daviwil/PowerShellEditorServices that referenced this issue Mar 25, 2017
This change causes the column number of the debugger's currently stopped
position to be passed through with the top stack frame.  This allows VS
Code's debugger UI to show an indicator that points to where the debugger
stopped when stepping through code.

Resolve PowerShell/vscode-powershell#616
@daviwil daviwil modified the milestones: Next Patch Update, 0.12.0 Apr 4, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants