allow notebook names with spaces

This commit is contained in:
Zachary Sailer 2013-07-21 15:50:18 -07:00 committed by MinRK
parent 5462cb4d9b
commit b170c5dee0
2 changed files with 4 additions and 1 deletions

View File

@ -22,6 +22,7 @@ HTTPError = web.HTTPError
from ..base.handlers import IPythonHandler
from ..utils import url_path_join
from urllib import quote
#-----------------------------------------------------------------------------
# Handlers
@ -50,6 +51,8 @@ class NamedNotebookHandler(IPythonHandler):
def get(self, notebook_path):
nbm = self.notebook_manager
name, path = nbm.named_notebook_path(notebook_path)
if name != None:
name = quote(name)
if path == None:
project = self.project + '/' + name
else:

View File

@ -53,7 +53,7 @@ class ProjectPathDashboardHandler(IPythonHandler):
project=project,
project_component=project.split('/'),
notebook_path=path,
notebook_name=name))
notebook_name=quote(name)))
class TreeRedirectHandler(IPythonHandler):