question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Undo does not work in Notebook Cells (confusion around cell level undo/redo stack)

See original GitHub issue

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

  • VS Code Version: Insiders
  • OS Version: Mac

Steps to Reproduce:

  1. Open an existing ipynb notebook
  2. Copy the last cell down (duplicate it)
  3. Hit the z key (it should get deleted)
  4. This works
  5. Next duplicate the cell again & click else where in the notebook (empty area below the last cell)
  6. Now set focus back to the last cell and hit z
  7. Nothing happens
  8. From now on, z will never work, undo command from the command palette too doesn’t work

I’ve tried enabling/disabling the setting Cell level undo/redo stack, no difference. I think there’s a confusion (discussed this in nb sync meeting) around what the Cell Level undo/redo stack does as well (or perhaps the confusion is due to the fact that this doesn’t seem to work).

TLDR: I wasn’t able to get undo/redo working reliably enough (in fact majority of the time it didn’t work as expected).

Issue Analytics

  • State:open
  • Created 2 years ago
  • Reactions:3
  • Comments:5 (2 by maintainers)

github_iconTop GitHub Comments

2reactions
nickeubankcommented, Sep 24, 2021

I just want to flag this as something that I think is pretty important to address – its really easy to lose a lot of work if an errant delete command deletes the wrong cell and there’s no undo.

0reactions
wwdokcommented, Jun 29, 2022

I have also found that i can only undo those operations in one cell, not the whole notebook, moreover, if i delete one cell, i can not undo it.

Read more comments on GitHub >

github_iconTop Results From Across the Web

How to recover accidentally deleted cells in Jupyter Notebook
Open the command pallet ( ctrl+shift+p on windows); Select the "Undo" command. Not sure why it works. Does vscode disable the ctrl-z shortcut ......
Read more >
v6: still no multiple undo? - Google Groups
This is the only app I run that doesn't happen multiple levels of undo. ... (NotebookAutoSave has been around for several versions.) Brett...
Read more >
Undo Framework Example | Qt Widgets 6.4.1
The undo stack is shown in a QUndoView, which is a list in which the commands are shown as list items. Undo and...
Read more >
November 2022 (version 1.74) - Visual Studio Code
Audio cues for notebooks and diff view - Sounds for cell run results, added or removed lines. Merge editor Undo/Redo - Quickly revert...
Read more >
What are the most common pitfalls awaiting new users?
What the @#%^&*?! do all those funny signs mean? Questions frequently arise about the meaning of the basic operators, and I hope it...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found