Skip to content

Commit

Permalink
Merge pull request #9580 from jasongrout/openbrowser
Browse files Browse the repository at this point in the history
Move open_browser to the top level configs of classes.
  • Loading branch information
blink1073 committed Jan 9, 2021
2 parents 9fd1548 + 3c02eff commit df5bb25
Show file tree
Hide file tree
Showing 6 changed files with 5 additions and 13 deletions.
3 changes: 2 additions & 1 deletion examples/example_check.py
Expand Up @@ -42,8 +42,9 @@ class App(mod.ExampleApp):
JS console errors, JS errors, and Python logged errors.
"""
name = __name__
open_browser = False

serverapp_config = {
"open_browser": False,
"base_url": "/foo/",
"root_dir": osp.abspath(example_dir)
}
Expand Down
3 changes: 2 additions & 1 deletion jupyterlab/browser_check.py
Expand Up @@ -175,8 +175,9 @@ class BrowserApp(LabApp):
JS console errors, JS errors, and Python logged errors.
"""
name = __name__
open_browser = False

serverapp_config = {
"open_browser": False,
"base_url": "/foo/"
}
ip = '127.0.0.1'
Expand Down
5 changes: 0 additions & 5 deletions jupyterlab/labapp.py
Expand Up @@ -546,11 +546,6 @@ class LabApp(NBClassicConfigShimMixin, LabServerApp):
expose_app_in_browser = Bool(False, config=True,
help="Whether to expose the global app instance to browser via window.jupyterlab")

# By default, open a browser for JupyterLab
serverapp_config = {
"open_browser": True
}

@default('app_dir')
def _default_app_dir(self):
app_dir = get_app_dir()
Expand Down
1 change: 0 additions & 1 deletion jupyterlab/labhubapp.py
Expand Up @@ -519,7 +519,6 @@ class OverrideSingleUserNotebookApp(SingleUserNotebookApp):

# Disable the default jupyterlab extension and enable ourself
serverapp_config = {
"open_browser": True,
"jpserver_extensions": { "jupyterlab": False, "jupyterlab.labhubapp": True }
}

Expand Down
4 changes: 0 additions & 4 deletions jupyterlab/tests/test_app.py
Expand Up @@ -256,10 +256,6 @@ class JestApp(ProcessTestApp):

test_config = Dict(dict(foo='bar'))

serverapp_config = {
"open_browser": False
}

@deprecated(removed_version=4)
def get_command(self):
"""Get the command to run"""
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Expand Up @@ -147,7 +147,7 @@ def run(self):
'tornado>=6.1.0',
'jupyter_core',
'jupyterlab_server~=2.0',
'jupyter_server~=1.1',
'jupyter_server~=1.2',
'nbclassic~=0.2',
'jinja2>=2.10'
]
Expand Down

0 comments on commit df5bb25

Please sign in to comment.