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

Only show notebook commands in Command Palette when a notebook is active #2636

Closed
stevenlis opened this issue Dec 2, 2019 · 7 comments
Closed
Assignees

Comments

@stevenlis
Copy link

When I call out the Command Palette while using notebook editor, there are too many commands appearing which doesn't support the notebook editor at all.

Please consider a way to only show notebook editor commands or make them distinguishable from other Python script commands.

image

@DavidKutu
Copy link

Thanks for the suggestion. I'm not sure if we can control that, but I'll take a look.

@stevenlis
Copy link
Author

I saw there is Python Refactor, so can we make a Python Notebook or something?

@IanMatthewHuff
Copy link
Member

Yeah, I'm not fully sure if we want to make this distinction. But at this point we do have a lot of data science specific commands, so it might be worth giving them their own category. We'll discuss it at triage.

@DonJayamanne
Copy link
Contributor

DonJayamanne commented Dec 3, 2019

I think it's better to hide the unnecessary commands, once that's done, we might not need a separate category.
E.g. debugging commands can be hidden until we start debugging. We could hide a number of other command based on the active cell (if markdown then house more commands).

If in notebook hide refactoring commands as those aren't supported.
Eg. Debug tests, run file in terminal, refactor, sort commands and the like can all be hidden when in a notebook.

Doing this will reduce the commands.

I think the main problem is the fact that we don't do a good job at hiding commands when they aren't relevant. It's just turning into a poorly managed (or unmanaged) list.

@greazer
Copy link
Member

greazer commented Dec 5, 2019

There are a couple options here. Maybe both. We can disable and hide commands that shouldn't be visible in our command palette. And we can create a new prefix. We should figure out what we should do.

@greazer
Copy link
Member

greazer commented Dec 5, 2019

Talking to Rong, we decided that the best course of action is to just filter out commands that are no applicable to our scenarios. We'll need to coordinate with the core extension to define the execution contexts.

@greazer greazer changed the title Only show notebook features in Command Palette Only show notebook commands in Command Palette Dec 5, 2019
@greazer greazer unassigned jmew Dec 5, 2019
@greazer greazer changed the title Only show notebook commands in Command Palette Only show notebook commands in Command Palette when a notebook is active Dec 5, 2019
@DonJayamanne DonJayamanne self-assigned this Feb 7, 2020
DonJayamanne referenced this issue in microsoft/vscode-python Feb 7, 2020
@rchiodo
Copy link
Contributor

rchiodo commented Feb 10, 2020

This is mostly working except for 'Run Selection in Interactive window' does not seem to show up as a command. That used to be there (seems like a regression then).

I'll enter another bug for that.
https://github.com/microsoft/vscode-python/issues/10030

@rchiodo rchiodo closed this as completed Feb 10, 2020
@lock lock bot locked as resolved and limited conversation to collaborators Feb 17, 2020
@microsoft microsoft unlocked this conversation Nov 14, 2020
@DonJayamanne DonJayamanne transferred this issue from microsoft/vscode-python Nov 14, 2020
@github-actions github-actions bot locked as resolved and limited conversation to collaborators May 7, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

7 participants