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

Notebook: support line numbers and actions to toggle it #106054

Closed
rebornix opened this issue Sep 3, 2020 · 9 comments
Closed

Notebook: support line numbers and actions to toggle it #106054

rebornix opened this issue Sep 3, 2020 · 9 comments
Assignees
Labels
feature-request Request for new features or functionality notebook on-testplan
Milestone

Comments

@rebornix
Copy link
Member

rebornix commented Sep 3, 2020

We may want to support users to customize their line numbers and allow them to toggle line numbers with shortcuts.

@rebornix rebornix self-assigned this Sep 3, 2020
@rebornix rebornix added this to the September 2020 milestone Sep 3, 2020
@rebornix rebornix added the feature-request Request for new features or functionality label Sep 3, 2020
@claudiaregio
Copy link

claudiaregio commented Sep 9, 2020

Question:

Would it look like this? (Numbering per cell)
Cell 1: 1 2 3
Cell 2: 1 2 3

image

Or like this? (Numbering for all code regardless of cell)
Cell 1: 1 2 3
Cell 2: 4 5 6
image

Would there be a way for users to pick which way they'd like to see it or is that what is meant by "support users to customize their line numbers"?

@DonJayamanne
Copy link
Contributor

I'd prefer we as extension authors could provide defaults as well.
If running the second cell & there are errors in the cell, then Jupyter returns line numbers in the error message, however the line numbers start from 1 for the cell that was executed.

I.e. in the case of Jupyter, we don't need line numbers in subsequent cells to continue from previous cells (at least not for our Python extension).

@joyceerhl
Copy link
Contributor

microsoft/vscode-jupyter#4810 is a related request to display the line and column number ticker in the status bar.

@rebornix
Copy link
Member Author

In Jupyter, users can press L to toggle the line numbers for active cell, or Shift+L to toggle line numbers for all cells (and this config is also persisted).

@claudiaregio
Copy link

@rebornix is this supposed to work today? Does Jupyter need to do anything to enable it? I tried this out in my notebook and it doesnt work :(

@Syndorik
Copy link

@claudiaregio as far as VScode insider is concerned, I don't think it works. I can't activate/deactivate the line number per celll either

@rebornix
Copy link
Member Author

We didn't have this yet. The note above is for me to capture what Jupyter does now.

@claudiaregio
Copy link

@rebornix ah ok this makes much more sense now, thanks

@rebornix rebornix modified the milestones: On Deck, April 2021 Apr 5, 2021
@rebornix
Copy link
Member Author

rebornix commented Apr 5, 2021

Fixed via 804c1fc .

@rebornix rebornix closed this as completed Apr 5, 2021
@rebornix rebornix added the verification-needed Verification of issue is requested label Apr 27, 2021
@rebornix rebornix removed the verification-needed Verification of issue is requested label Apr 27, 2021
@github-actions github-actions bot locked and limited conversation to collaborators May 20, 2021
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 notebook on-testplan
Projects
None yet
Development

No branches or pull requests

6 participants