-
Notifications
You must be signed in to change notification settings - Fork 298
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
Format cell on run like the nb_black extension does. #7058
Comments
Thanks for the suggestion. We'll look at it in our weekly triage. It will probably need a bunch of upvotes before it's considered. |
Thanks! Since black catches syntax errors, it's kinda related to this too, no? #1482 |
+1 code format inside cell is the last reason I still keep jupyter-lab on my system. |
Just FYI, black now supports Jupyter Notebooks and even has a |
That would be very helpful indeed! Thanks for considering! |
Any news regarding this? I would personally prefer to have the formatting done on save, and not when running a cell. |
Sorry but it's not planned at the moment. |
Spent 1/2 hour trying to figure out why it's not working... some hint in the config section would be nice. |
Could you please reconsider this again? Cheers. |
You can add the |
This feature will be in the next insiders build, and can be enabled by adding the following into your settings json: |
Awesome, thanks!
…On Mon, May 22, 2023, 21:52 Michael Lively ***@***.***> wrote:
This feature will be in the next insiders build, and can be enabled by
adding the following into your settings json:
"notebook.formatOnCellExecution": true
—
Reply to this email directly, view it on GitHub
<#7058 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAFBERMIFG7HDLZOJO7EZJTXHPGYRANCNFSM5B47I5OQ>
.
You are receiving this because you are subscribed to this thread.Message
ID: ***@***.***>
|
One of my favorite features of vscode (and other good editors) is format on save. Obviously that's not feasible for notebooks because they aren't linear and so a formatter would struggle if it tried to parse everything every time the notebook was saved. But there is a solution that's like format on save for notebooks: format on run.
Now that notebook cells can be formatted, would it be possible to create a setting where each cell is formatted when it's run? It's already available in regular jupyter notebooks thanks to nb_black, and I'd love to see it in VS code notebooks.
The text was updated successfully, but these errors were encountered: