mirror of
https://github.com/jupyter/notebook.git
synced 2024-11-27 03:20:27 +08:00
Update shim, notebook app name
This commit is contained in:
parent
46afe5014e
commit
e5fefbae07
@ -19,7 +19,7 @@ The `jlpm` command is JupyterLab's pinned version of [yarn](https://yarnpkg.com/
|
||||
mamba create -n notebook -c conda-forge python nodejs -y
|
||||
|
||||
# activate the environment
|
||||
conda activate notebook
|
||||
mamba activate notebook
|
||||
|
||||
# Install package in development mode
|
||||
pip install -e .
|
||||
|
@ -1,3 +1,4 @@
|
||||
{
|
||||
"LabApp": { "collaborative": true, "expose_app_in_browser": true }
|
||||
"LabApp": { "collaborative": true, "expose_app_in_browser": true },
|
||||
"JupyterNotebookApp": { "collaborative": true, "expose_app_in_browser": true }
|
||||
}
|
||||
|
@ -2,20 +2,14 @@ from ._version import __version__
|
||||
|
||||
|
||||
def _jupyter_server_extension_paths():
|
||||
return [
|
||||
{
|
||||
'module': 'notebook'
|
||||
}
|
||||
]
|
||||
return [{"module": "notebook"}]
|
||||
|
||||
|
||||
def _jupyter_server_extension_points():
|
||||
from .app import NotebookApp
|
||||
return [{"module": "notebook", "app": NotebookApp}]
|
||||
from .app import JupyterNotebookApp
|
||||
|
||||
return [{"module": "notebook", "app": JupyterNotebookApp}]
|
||||
|
||||
|
||||
def _jupyter_labextension_paths():
|
||||
return [{
|
||||
'src': 'labextension',
|
||||
'dest': '@jupyter-notebook/lab-extension'
|
||||
}]
|
||||
return [{"src": "labextension", "dest": "@jupyter-notebook/lab-extension"}]
|
||||
|
@ -13,6 +13,7 @@ from jupyterlab.commands import get_app_dir, get_user_settings_dir, get_workspac
|
||||
from jupyterlab_server import LabServerApp
|
||||
from jupyterlab_server.config import get_page_config, recursive_update, LabConfig
|
||||
from jupyterlab_server.handlers import is_url, _camelCase
|
||||
from notebook_shim.shim import NotebookConfigShimMixin
|
||||
from tornado import web
|
||||
from tornado.gen import maybe_future
|
||||
from traitlets import Bool
|
||||
@ -168,13 +169,13 @@ class NotebookHandler(NotebookBaseHandler):
|
||||
aliases = dict(base_aliases)
|
||||
|
||||
|
||||
class NotebookApp(LabServerApp):
|
||||
class JupyterNotebookApp(NotebookConfigShimMixin, LabServerApp):
|
||||
name = "notebook"
|
||||
app_name = "Jupyter Notebook"
|
||||
description = "Jupyter Notebook - A web-based notebook environment for interactive computing"
|
||||
version = version
|
||||
app_version = version
|
||||
extension_url = "/tree"
|
||||
extension_url = "/"
|
||||
default_url = "/tree"
|
||||
file_url_prefix = "/notebooks"
|
||||
load_other_extensions = True
|
||||
@ -237,7 +238,7 @@ class NotebookApp(LabServerApp):
|
||||
super().initialize()
|
||||
|
||||
|
||||
main = launch_new_instance = NotebookApp.launch_instance
|
||||
main = launch_new_instance = JupyterNotebookApp.launch_instance
|
||||
|
||||
if __name__ == "__main__":
|
||||
main()
|
||||
|
@ -4,7 +4,7 @@ module.exports = {
|
||||
...baseConfig,
|
||||
timeout: 240000,
|
||||
use: {
|
||||
appPath: '/'
|
||||
appPath: ''
|
||||
},
|
||||
retries: 1
|
||||
};
|
||||
|
@ -8,4 +8,5 @@ c.ServerApp.root_dir = mkdtemp(prefix="galata-test-")
|
||||
c.ServerApp.token = ""
|
||||
c.ServerApp.password = ""
|
||||
c.ServerApp.disable_check_xsrf = True
|
||||
c.NotebookApp.expose_app_in_browser = True
|
||||
|
||||
c.JupyterNotebookApp.expose_app_in_browser = True
|
||||
|
Loading…
Reference in New Issue
Block a user