Skip to content

Commit cafb327

Browse files
committed
allow None in non-ExtensionApp extensions
1 parent c36acab commit cafb327

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

jupyter_server/serverapp.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1491,7 +1491,9 @@ def init_server_extension_config(self):
14911491
for modulename in sorted(self.jpserver_extensions):
14921492
_, metadata = _get_server_extension_metadata(modulename)
14931493
app_obj = metadata[0].get('app', None)
1494-
if issubclass(app_obj, JupyterApp):
1494+
if app_obj:
1495+
if not issubclass(app_obj, JupyterApp):
1496+
raise TypeError(abb_obj.__name__ + "must be a subclass of JupyterApp")
14951497
# Initialize extension app
14961498
app = app_obj(parent=self)
14971499
# Update the app's config, setting

0 commit comments

Comments
 (0)