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

Verified false breakpoint w/message does not reflect message in breakpoint list UI #4935

Closed
rkeithhill opened this issue Apr 5, 2016 · 10 comments
Assignees
Labels
debug Debug viewlet, configurations, breakpoints, adapter issues feature-request Request for new features or functionality verified Verification succeeded
Milestone

Comments

@rkeithhill
Copy link

  • VSCode Version: 0.10.14-insider
  • OS Version: Windows 10 1511

Steps to Reproduce:

  1. Install PowerShell extension
  2. Open Examples folder under the PowerShell extension directory
  3. Set a breakpoint in DebugTest.ps1 on any line (with script on it).
  4. Close VSCode and from Windows explorer or console, rename DebugTest.ps1 to DebugTest2.ps1
  5. Reopen VSCode and the Examples folder. Note in the Debug view, the breakpoint is still set on DebugTest.ps1
  6. Select the DebugTest2.ps1 file and start debugging the script.
  7. Note that there is no indication that the breakpoint in the Debug view didn't get set.

I would have expected at least the tooltip to display the message that we return from the debug host e.g.:

    {
      "type": "response",
      "request_seq": "2",
      "command": "setBreakpoints",
      "success": true,
      "body": {
        "breakpoints": [
          {
            "verified": false,
            "message": "Source does not exist, breakpoint not set.",
            "source": "c:\\Users\\Keith\\.vscode-insiders\\extensions\\ms-vscode.PowerShell-0.5.0\\examples\\DebugTest.ps1",
            "line": 23,
            "column": null
          }
        ]
      }
    }

I get that the message is normally meant for the tooltip on the breakpoint glyph in the editor gutter but if the user doesn't happen to have that file open (or it does not exist anymore), they won't see the error.

I think the breakpoints list in the Debug should "reflect" breakpoints that failed verification and provide the user with a way to see the message returned by the debug host.

PowerShell/PowerShellEditorServices#195

@rkeithhill rkeithhill changed the title Verified false breakpoint w/message does not reflect message in UI Verified false breakpoint w/message does not reflect message in breakpoint list UI Apr 5, 2016
@isidorn isidorn added feature-request Request for new features or functionality debug Debug viewlet, configurations, breakpoints, adapter issues labels Apr 14, 2016
@isidorn isidorn added this to the Backlog milestone Apr 14, 2016
@isidorn
Copy link
Contributor

isidorn commented Apr 14, 2016

@rkeithhill and where would you show that message in the breakpoints view without introducing too much clutter? I suggest to show it on hover. What do you think?

@rkeithhill
Copy link
Author

@isidorn Yeah but I was also thinking that the Breakpoints viewlet could show a glyph indicating there is a problem with the breakpoint and then provide a tooltip (hover as you put it) to display the message e.g.:

vscode_invalid_breakpoint

But if you don't like the extra glyph - maybe the checkbox is shown in an indeterminate state? Or perhaps the breakpoint text is red or perhaps the text uses strike-through. You just need some sort of indication to draw their attention and then the hover would explain why the breakpoint wasn't set.

@isidorn isidorn modified the milestones: April 2016, Backlog Apr 15, 2016
@isidorn
Copy link
Contributor

isidorn commented Apr 22, 2016

Now if the breakpoint is unverified we show the message on hover and we show the whole breakpoint grayed out - same as how we show all breakpoints when you deactivate them.
Let me know if you like it

@isidorn isidorn assigned weinand and unassigned isidorn Apr 22, 2016
@vsccarl
Copy link

vsccarl commented Apr 28, 2016

@isidorn I'm not able to verify this fix in the latest alpha. With the breakpoint set in the now nonexistent original DebugTest.ps1 I am also not able to debug other files.

@vsccarl vsccarl reopened this Apr 28, 2016
@rkeithhill
Copy link
Author

rkeithhill commented Apr 28, 2016

@vsccarl the issue with not being able to debug with the PowerShell is a known issue with the PowerShell extension. We should have a fixed version (0.6.0) released in a week or so. For now, you can work around this by setting a breakpoint in your program and then you should be able to debug.

That said I'm not seeing this issue as fixed on my machine at work with today's alpha build. I will need to check later tonight on my home dev machine with daily 0.6.0 PS extension bits.

@rkeithhill
Copy link
Author

@isidorn OK, checked the PSES ext daily bits and I still don't see the breakpoint grayed out and there is no hover tip. Now I am checking this in the BREAKPOINTS viewlet which I assume is what you're talking about, right? Because the breakpoints in question are for files that no longer exist so it would be impossible to see the grayed out breakpoint in the editor window. :-)

@isidorn isidorn assigned isidorn and unassigned weinand Apr 29, 2016
@isidorn isidorn modified the milestones: May 2016, April 2016 Apr 29, 2016
@isidorn
Copy link
Contributor

isidorn commented Apr 29, 2016

@rkeithhill yeah, it is in the breakpoints veiwlet :) Today is last game of endgame, which means we only look at critical bugs, thus I will investigate why is this not fixed on monday, though that means it will only be available in our may release.
I myself have seen this working in action. Are you sure the adapter sends verified false for these breakpoitns?

@rkeithhill
Copy link
Author

Yes we set verified to false. Is there anything else in this response message that might be wrong?

Log file snippet from debug session:

    WRITE MESSAGE:

    {
      "type": "response",
      "request_seq": "3",
      "command": "setBreakpoints",
      "success": true,
      "body": {
        "breakpoints": [
          {
            "verified": false,
            "message": "Source does not exist, breakpoint not set.",
            "source": "c:\\Users\\Keith\\.vscode-alpha\\extensions\\ms-vscode.PowerShell-0.5.0\\examples\\DebugTest.ps1",
            "line": 18,
            "column": null
          }
        ]
      }
    }

@isidorn isidorn closed this as completed in ba2c224 May 6, 2016
@isidorn
Copy link
Contributor

isidorn commented May 6, 2016

Found the issue - now it should work

@isidorn isidorn assigned weinand and unassigned isidorn May 6, 2016
@rkeithhill
Copy link
Author

@isidorn I've confirmed the fix. Thanks!

@isidorn isidorn added the verified Verification succeeded label May 9, 2016
@vscodebot vscodebot bot locked and limited conversation to collaborators Nov 18, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
debug Debug viewlet, configurations, breakpoints, adapter issues feature-request Request for new features or functionality verified Verification succeeded
Projects
None yet
Development

No branches or pull requests

4 participants