How to recover deleted iPython Notebooks

后端 未结 12 867
礼貌的吻别
礼貌的吻别 2020-12-03 11:05

I have iPython Notebook through Anaconda. I accidentally deleted an important notebook, and I can\'t seem to find it in trash (I don\'t think iPy Notebooks go to the trash).

12条回答
  •  旧时难觅i
    2020-12-03 11:38

    If you are running on Jupyterlab on linux like me. What I did is went into command prompt and went to my trash folder.

    Trash directories on linux are typically

    /home/$USER/.local/share/Trash
    

    or

    If you deleted something as root (e.g. deleted a file using Nautilus invoked via gksu), it is at

    /root/.local/share/Trash
    

    I ended up changing directories to /home/$USER/.local/share/Trash/files and my deleted notebook was there! depending on how you access your backend you could also try /home/jupyter/.local/share/Trash/

    ps If you are having issues changing directories from Trash to files due to permissions dont forget to become root:

    sudo -i
    

    and the move to your files from there.

    Best of luck,

提交回复
热议问题