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

window.showInputBox should show which extension triggered it #136856

Closed
Merlin2001 opened this issue Nov 10, 2021 · 5 comments
Closed

window.showInputBox should show which extension triggered it #136856

Merlin2001 opened this issue Nov 10, 2021 · 5 comments
Assignees
Labels
feature-request Request for new features or functionality quick-pick Quick-pick widget issues

Comments

@Merlin2001
Copy link

Merlin2001 commented Nov 10, 2021

Does this issue occur when all extensions are disabled?: Yes

  • VS Code Version:
    Version: 1.62.1 (user setup)
    Commit: f4af3cb
    Date: 2021-11-05T10:57:55.946Z
    Electron: 13.5.2
    Chrome: 91.0.4472.164
    Node.js: 14.16.0
    V8: 9.1.269.39-electron.0

  • OS Version:
    OS: Windows_NT x64 10.0.19043

Steps to Reproduce

  1. Install @ankitbko's Azure DevOps Pull Requests extension
  2. Don't follow the guide to login, instead close VS Code
  3. Start VS Code

VS Code will now show the following Input Box:

Please provide PAT (Press 'Enter' to confirm or 'Escape' to cancel)

The problem is that there is no hint whatsoever which extension opened that input box, so in my case it took me ages to find out (by accident) that this was due to the AZDO extension. I have filed a PR for the extension to have the extension name be prepended to the input box message in the meantime.

But I think a better and more general solution would be to append the extension name in square brackets after the prompt:
Please provide PAT (Press 'Enter' to confirm or 'Escape' to cancel) [Azure DevOps Pull Requests]

Merlin2001 added a commit to Merlin2001/vscode-pull-request-azdo that referenced this issue Nov 10, 2021
This is so the user has a clue what kind of PAT is required and which extension sent the request. There's also an [open issue](microsoft/vscode#136856) for VS Code to automatically show this information (which would mean we could revert to the old prompt or use `Please provide PAT for Azure DevOps access`)
@gjsjohnmurray
Copy link
Contributor

Instead of appending text to every prompt, maybe add an Info codicon somewhere which the user can hover over or click to discover the originating extension.

@TylerLeonhardt
Copy link
Member

Couple things:

  1. This extension (and really any extension) shouldn't prompt out of the blue. You should have taken an explicit action to get this quick pick and thus this feature request wouldn't be needed.
  2. For this particular case, this extension should be using our Authentication APIs which would ensure ^^^^ this happens.

I do like the info codicon idea though... because I'm sure there are plenty of extensions that are doing similar things. I'll assign it to the Backlog Candidates to see if other folks feel the same way about quick picks.

@TylerLeonhardt TylerLeonhardt added this to the Backlog Candidates milestone Nov 12, 2021
@TylerLeonhardt TylerLeonhardt added quick-pick Quick-pick widget issues feature-request Request for new features or functionality labels Nov 12, 2021
@github-actions github-actions bot locked and limited conversation to collaborators Feb 27, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
feature-request Request for new features or functionality quick-pick Quick-pick widget issues
Projects
None yet
Development

No branches or pull requests

4 participants
@TylerLeonhardt @gjsjohnmurray @Merlin2001 and others