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

Colons in notebook name causes notebook deletion without warning #1781

Closed
ghost opened this issue May 29, 2012 · 1 comment
Closed

Colons in notebook name causes notebook deletion without warning #1781

ghost opened this issue May 29, 2012 · 1 comment
Milestone

Comments

@ghost
Copy link

ghost commented May 29, 2012

If you change the name of a notebook by clicking on the notebook title in the browser, and the new name includes a colon, the notebook is "saved" without objection, while in the background the ipynb file is wiped -- the filename is truncated at the colon and the file is empty. This is not apparent in the browser until you close the notebook. This is on Windows.

I discovered this by successively changing the names of a set of 5 notebooks to include colons, and continued to make changes to the notebooks, saving, etc. Then I closed them and later went to re-open them to discover everything was gone. There was never any warning at all while in the browser. Given that there is no warning that the notebook title == filename and colons are a fairly common character, this strikes me as a pretty serious issue!

@bfroehle
Copy link
Contributor

The easiest way to fix this might be to add a list of reserved characters to notebook_name_blacklist_re and a corresponding note in the save widget.

Note that this bug does not impact my linux installation.

@minrk minrk closed this as completed in 66a567b Jun 6, 2012
mattvonrocketstein pushed a commit to mattvonrocketstein/ipython that referenced this issue Nov 3, 2014
Make : invalid in filenames in the Notebook JS code.

This only prevents : in the filenames on the JavaScript side of things. Handling this on the server side will be a separate issue that is related to other open issue. I will update those to reflect this. 

closes ipython#1781
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants