##// END OF EJS Templates
allow kernel_name to be undefined in requests...
MinRK -
Show More
@@ -45,7 +45,8 b' class SessionRootHandler(IPythonHandler):'
45 45 try:
46 46 kernel_name = model['kernel']['name']
47 47 except KeyError:
48 raise web.HTTPError(400, "Missing field in JSON data: kernel.name")
48 self.log.debug("No kernel name specified, using default kernel")
49 kernel_name = None
49 50
50 51 # Check to see if session exists
51 52 if sm.session_exists(name=name, path=path):
@@ -1,20 +1,7 b''
1 """A base class session manager.
1 """A base class session manager."""
2 2
3 Authors:
4
5 * Zach Sailer
6 """
7
8 #-----------------------------------------------------------------------------
9 # Copyright (C) 2013 The IPython Development Team
10 #
11 # Distributed under the terms of the BSD License. The full license is in
12 # the file COPYING, distributed as part of this software.
13 #-----------------------------------------------------------------------------
14
15 #-----------------------------------------------------------------------------
16 # Imports
17 #-----------------------------------------------------------------------------
3 # Copyright (c) IPython Development Team.
4 # Distributed under the terms of the Modified BSD License.
18 5
19 6 import uuid
20 7 import sqlite3
@@ -25,9 +12,6 b' from IPython.config.configurable import LoggingConfigurable'
25 12 from IPython.utils.py3compat import unicode_type
26 13 from IPython.utils.traitlets import Instance
27 14
28 #-----------------------------------------------------------------------------
29 # Classes
30 #-----------------------------------------------------------------------------
31 15
32 16 class SessionManager(LoggingConfigurable):
33 17
@@ -73,7 +57,7 b' class SessionManager(LoggingConfigurable):'
73 57 "Create a uuid for a new session"
74 58 return unicode_type(uuid.uuid4())
75 59
76 def create_session(self, name=None, path=None, kernel_name='python'):
60 def create_session(self, name=None, path=None, kernel_name=None):
77 61 """Creates a session and returns its model"""
78 62 session_id = self.new_session_id()
79 63 # allow nbm to specify kernels cwd
General Comments 0
You need to be logged in to leave comments. Login now