From 9012ac2e9039ffebb11f72be84f97db97767b72d Mon Sep 17 00:00:00 2001 From: Landung 'Don' Setiawan Date: Thu, 22 Jun 2023 14:12:02 -0700 Subject: [PATCH 01/36] Initial setup for codespaces --- .devcontainer/Dockerfile | 1 + .devcontainer/devcontainer.json | 18 ++++++++++++++++++ .devcontainer/environment.yml | 1 + 3 files changed, 20 insertions(+) create mode 100644 .devcontainer/Dockerfile create mode 100644 .devcontainer/devcontainer.json create mode 120000 .devcontainer/environment.yml diff --git a/.devcontainer/Dockerfile b/.devcontainer/Dockerfile new file mode 100644 index 00000000..0964bf48 --- /dev/null +++ b/.devcontainer/Dockerfile @@ -0,0 +1 @@ +FROM pangeo/base-image:2023.06.20 diff --git a/.devcontainer/devcontainer.json b/.devcontainer/devcontainer.json new file mode 100644 index 00000000..c5ec37fa --- /dev/null +++ b/.devcontainer/devcontainer.json @@ -0,0 +1,18 @@ +{ + "build": { + "dockerfile": "./Dockerfile", + "context": "." + }, + "hostRequirements": { + "cpus": 2, + "memory": "4gb", + "storage": "32gb" + }, + "customizations": { + "codespaces": { + "openFiles": [ + "workshops/scipy2023/index.ipynb" + ] + } + } +} \ No newline at end of file diff --git a/.devcontainer/environment.yml b/.devcontainer/environment.yml new file mode 120000 index 00000000..faafc0cc --- /dev/null +++ b/.devcontainer/environment.yml @@ -0,0 +1 @@ +../conda/environment.yml \ No newline at end of file From 45714b1f72d6116fefaf103e82373a723803b1e7 Mon Sep 17 00:00:00 2001 From: Landung 'Don' Setiawan Date: Thu, 22 Jun 2023 14:24:47 -0700 Subject: [PATCH 02/36] Change build context --- .devcontainer/devcontainer.json | 2 +- .devcontainer/environment.yml | 1 - 2 files changed, 1 insertion(+), 2 deletions(-) delete mode 120000 .devcontainer/environment.yml diff --git a/.devcontainer/devcontainer.json b/.devcontainer/devcontainer.json index c5ec37fa..0706581e 100644 --- a/.devcontainer/devcontainer.json +++ b/.devcontainer/devcontainer.json @@ -1,7 +1,7 @@ { "build": { "dockerfile": "./Dockerfile", - "context": "." + "context": "../conda" }, "hostRequirements": { "cpus": 2, diff --git a/.devcontainer/environment.yml b/.devcontainer/environment.yml deleted file mode 120000 index faafc0cc..00000000 --- a/.devcontainer/environment.yml +++ /dev/null @@ -1 +0,0 @@ -../conda/environment.yml \ No newline at end of file From bfb6c67a058ec57e03397d727fd5420c347bbe9d Mon Sep 17 00:00:00 2001 From: Landung 'Don' Setiawan Date: Thu, 22 Jun 2023 14:35:58 -0700 Subject: [PATCH 03/36] Add apt.txt --- conda/apt.txt | 2 ++ 1 file changed, 2 insertions(+) create mode 100644 conda/apt.txt diff --git a/conda/apt.txt b/conda/apt.txt new file mode 100644 index 00000000..82d0355f --- /dev/null +++ b/conda/apt.txt @@ -0,0 +1,2 @@ +git +vim From f6c04c5516109502c963dbd9ba435856db17d311 Mon Sep 17 00:00:00 2001 From: Landung 'Don' Setiawan Date: Thu, 22 Jun 2023 14:56:28 -0700 Subject: [PATCH 04/36] Add jupyter and python extensions for vscode --- .devcontainer/devcontainer.json | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/.devcontainer/devcontainer.json b/.devcontainer/devcontainer.json index 0706581e..6b096762 100644 --- a/.devcontainer/devcontainer.json +++ b/.devcontainer/devcontainer.json @@ -4,15 +4,19 @@ "context": "../conda" }, "hostRequirements": { - "cpus": 2, - "memory": "4gb", - "storage": "32gb" + "cpus": 4 }, "customizations": { "codespaces": { "openFiles": [ "workshops/scipy2023/index.ipynb" ] + }, + "vscode": { + "extensions": [ + "ms-toolsai.jupyter", + "ms-python.python" + ] } } } \ No newline at end of file From 290caeec3a46a98d82881bf0052884317c9424d1 Mon Sep 17 00:00:00 2001 From: Landung 'Don' Setiawan Date: Thu, 22 Jun 2023 14:57:43 -0700 Subject: [PATCH 05/36] Modify cpu requirement to 2 --- .devcontainer/devcontainer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.devcontainer/devcontainer.json b/.devcontainer/devcontainer.json index 6b096762..b87b11e1 100644 --- a/.devcontainer/devcontainer.json +++ b/.devcontainer/devcontainer.json @@ -4,7 +4,7 @@ "context": "../conda" }, "hostRequirements": { - "cpus": 4 + "cpus": 2 }, "customizations": { "codespaces": { From 6d0ad47598f94889ab77517278f6542814d2c174 Mon Sep 17 00:00:00 2001 From: Landung 'Don' Setiawan Date: Thu, 22 Jun 2023 15:12:59 -0700 Subject: [PATCH 06/36] Remove apt.txt, don't need it --- conda/apt.txt | 2 -- 1 file changed, 2 deletions(-) delete mode 100644 conda/apt.txt diff --git a/conda/apt.txt b/conda/apt.txt deleted file mode 100644 index 82d0355f..00000000 --- a/conda/apt.txt +++ /dev/null @@ -1,2 +0,0 @@ -git -vim From 7bd28fafd0d497a82ba904ba18faf87140c8c7a6 Mon Sep 17 00:00:00 2001 From: Landung 'Don' Setiawan Date: Thu, 22 Jun 2023 15:16:57 -0700 Subject: [PATCH 07/36] Open README.md by default on vscode --- .devcontainer/devcontainer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.devcontainer/devcontainer.json b/.devcontainer/devcontainer.json index b87b11e1..864ce881 100644 --- a/.devcontainer/devcontainer.json +++ b/.devcontainer/devcontainer.json @@ -9,7 +9,7 @@ "customizations": { "codespaces": { "openFiles": [ - "workshops/scipy2023/index.ipynb" + "workshops/scipy2023/README.md" ] }, "vscode": { From 6be8ecb7438a4f28d3031f146649d67911bd702e Mon Sep 17 00:00:00 2001 From: Landung 'Don' Setiawan Date: Thu, 22 Jun 2023 15:28:42 -0700 Subject: [PATCH 08/36] Move codespaces to scipy 2023 and add apt txt for git and vim --- .devcontainer/{ => scipy2023}/devcontainer.json | 4 ++-- conda/apt.txt | 2 ++ 2 files changed, 4 insertions(+), 2 deletions(-) rename .devcontainer/{ => scipy2023}/devcontainer.json (83%) create mode 100644 conda/apt.txt diff --git a/.devcontainer/devcontainer.json b/.devcontainer/scipy2023/devcontainer.json similarity index 83% rename from .devcontainer/devcontainer.json rename to .devcontainer/scipy2023/devcontainer.json index 864ce881..798d8418 100644 --- a/.devcontainer/devcontainer.json +++ b/.devcontainer/scipy2023/devcontainer.json @@ -1,7 +1,7 @@ { "build": { - "dockerfile": "./Dockerfile", - "context": "../conda" + "dockerfile": "../Dockerfile", + "context": "../../conda" }, "hostRequirements": { "cpus": 2 diff --git a/conda/apt.txt b/conda/apt.txt new file mode 100644 index 00000000..82d0355f --- /dev/null +++ b/conda/apt.txt @@ -0,0 +1,2 @@ +git +vim From ea3e21cbb2c15a0a349018fff581f0d7fe3c30cf Mon Sep 17 00:00:00 2001 From: Landung 'Don' Setiawan Date: Thu, 22 Jun 2023 15:43:16 -0700 Subject: [PATCH 09/36] Move all to .binder and add jupyterlab config --- {conda => .binder}/apt.txt | 0 .binder/jupyter_lab_config.py | 1105 +++++++++++++++++++++ .devcontainer/scipy2023/devcontainer.json | 2 +- 3 files changed, 1106 insertions(+), 1 deletion(-) rename {conda => .binder}/apt.txt (100%) create mode 100644 .binder/jupyter_lab_config.py diff --git a/conda/apt.txt b/.binder/apt.txt similarity index 100% rename from conda/apt.txt rename to .binder/apt.txt diff --git a/.binder/jupyter_lab_config.py b/.binder/jupyter_lab_config.py new file mode 100644 index 00000000..c32ddd8f --- /dev/null +++ b/.binder/jupyter_lab_config.py @@ -0,0 +1,1105 @@ +# Configuration file for lab. + +c = get_config() #noqa + +#------------------------------------------------------------------------------ +# Application(SingletonConfigurable) configuration +#------------------------------------------------------------------------------ +## This is an application. + +## The date format used by logging formatters for %(asctime)s +# Default: '%Y-%m-%d %H:%M:%S' +# c.Application.log_datefmt = '%Y-%m-%d %H:%M:%S' + +## The Logging format template +# Default: '[%(name)s]%(highlevel)s %(message)s' +# c.Application.log_format = '[%(name)s]%(highlevel)s %(message)s' + +## Set the log level by value or name. +# Choices: any of [0, 10, 20, 30, 40, 50, 'DEBUG', 'INFO', 'WARN', 'ERROR', 'CRITICAL'] +# Default: 30 +# c.Application.log_level = 30 + +## Configure additional log handlers. +# +# The default stderr logs handler is configured by the log_level, log_datefmt +# and log_format settings. +# +# This configuration can be used to configure additional handlers (e.g. to +# output the log to a file) or for finer control over the default handlers. +# +# If provided this should be a logging configuration dictionary, for more +# information see: +# https://docs.python.org/3/library/logging.config.html#logging-config- +# dictschema +# +# This dictionary is merged with the base logging configuration which defines +# the following: +# +# * A logging formatter intended for interactive use called +# ``console``. +# * A logging handler that writes to stderr called +# ``console`` which uses the formatter ``console``. +# * A logger with the name of this application set to ``DEBUG`` +# level. +# +# This example adds a new handler that writes to a file: +# +# .. code-block:: python +# +# c.Application.logging_config = { +# 'handlers': { +# 'file': { +# 'class': 'logging.FileHandler', +# 'level': 'DEBUG', +# 'filename': '', +# } +# }, +# 'loggers': { +# '': { +# 'level': 'DEBUG', +# # NOTE: if you don't list the default "console" +# # handler here then it will be disabled +# 'handlers': ['console', 'file'], +# }, +# } +# } +# Default: {} +# c.Application.logging_config = {} + +## Instead of starting the Application, dump configuration to stdout +# Default: False +# c.Application.show_config = False + +## Instead of starting the Application, dump configuration to stdout (as JSON) +# Default: False +# c.Application.show_config_json = False + +#------------------------------------------------------------------------------ +# JupyterApp(Application) configuration +#------------------------------------------------------------------------------ +## Base class for Jupyter applications + +## Answer yes to any prompts. +# Default: False +# c.JupyterApp.answer_yes = False + +## Full path of a config file. +# Default: '' +# c.JupyterApp.config_file = '' + +## Specify a config file to load. +# Default: '' +# c.JupyterApp.config_file_name = '' + +## Generate default config file. +# Default: False +# c.JupyterApp.generate_config = False + +## The date format used by logging formatters for %(asctime)s +# See also: Application.log_datefmt +# c.JupyterApp.log_datefmt = '%Y-%m-%d %H:%M:%S' + +## The Logging format template +# See also: Application.log_format +# c.JupyterApp.log_format = '[%(name)s]%(highlevel)s %(message)s' + +## Set the log level by value or name. +# See also: Application.log_level +# c.JupyterApp.log_level = 30 + +## +# See also: Application.logging_config +# c.JupyterApp.logging_config = {} + +## Instead of starting the Application, dump configuration to stdout +# See also: Application.show_config +# c.JupyterApp.show_config = False + +## Instead of starting the Application, dump configuration to stdout (as JSON) +# See also: Application.show_config_json +# c.JupyterApp.show_config_json = False + +#------------------------------------------------------------------------------ +# ExtensionApp(JupyterApp) configuration +#------------------------------------------------------------------------------ +## Base class for configurable Jupyter Server Extension Applications. +# +# ExtensionApp subclasses can be initialized two ways: +# +# - Extension is listed as a jpserver_extension, and ServerApp calls +# its load_jupyter_server_extension classmethod. This is the +# classic way of loading a server extension. +# +# - Extension is launched directly by calling its `launch_instance` +# class method. This method can be set as a entry_point in +# the extensions setup.py. + +## Answer yes to any prompts. +# See also: JupyterApp.answer_yes +# c.ExtensionApp.answer_yes = False + +## Full path of a config file. +# See also: JupyterApp.config_file +# c.ExtensionApp.config_file = '' + +## Specify a config file to load. +# See also: JupyterApp.config_file_name +# c.ExtensionApp.config_file_name = '' + +# Default: '' +# c.ExtensionApp.default_url = '' + +## Generate default config file. +# See also: JupyterApp.generate_config +# c.ExtensionApp.generate_config = False + +## Handlers appended to the server. +# Default: [] +# c.ExtensionApp.handlers = [] + +## The date format used by logging formatters for %(asctime)s +# See also: Application.log_datefmt +# c.ExtensionApp.log_datefmt = '%Y-%m-%d %H:%M:%S' + +## The Logging format template +# See also: Application.log_format +# c.ExtensionApp.log_format = '[%(name)s]%(highlevel)s %(message)s' + +## Set the log level by value or name. +# See also: Application.log_level +# c.ExtensionApp.log_level = 30 + +## +# See also: Application.logging_config +# c.ExtensionApp.logging_config = {} + +## Whether to open in a browser after starting. +# The specific browser used is platform dependent and +# determined by the python standard library `webbrowser` +# module, unless it is overridden using the --browser +# (ServerApp.browser) configuration option. +# Default: False +# c.ExtensionApp.open_browser = False + +## Settings that will passed to the server. +# Default: {} +# c.ExtensionApp.settings = {} + +## Instead of starting the Application, dump configuration to stdout +# See also: Application.show_config +# c.ExtensionApp.show_config = False + +## Instead of starting the Application, dump configuration to stdout (as JSON) +# See also: Application.show_config_json +# c.ExtensionApp.show_config_json = False + +## paths to search for serving static files. +# +# This allows adding javascript/css to be available from the notebook server machine, +# or overriding individual files in the IPython +# Default: [] +# c.ExtensionApp.static_paths = [] + +## Url where the static assets for the extension are served. +# Default: '' +# c.ExtensionApp.static_url_prefix = '' + +## Paths to search for serving jinja templates. +# +# Can be used to override templates from notebook.templates. +# Default: [] +# c.ExtensionApp.template_paths = [] + +#------------------------------------------------------------------------------ +# LabServerApp(ExtensionApp) configuration +#------------------------------------------------------------------------------ +## A Lab Server Application that runs out-of-the-box + +## "A list of comma-separated URIs to get the allowed extensions list +# +# .. versionchanged:: 2.0.0 +# `LabServerApp.whitetlist_uris` renamed to `allowed_extensions_uris` +# Default: '' +# c.LabServerApp.allowed_extensions_uris = '' + +## Answer yes to any prompts. +# See also: JupyterApp.answer_yes +# c.LabServerApp.answer_yes = False + +## The application settings directory. +# Default: '' +# c.LabServerApp.app_settings_dir = '' + +## The url path for the application. +# Default: '/lab' +# c.LabServerApp.app_url = '/lab' + +## Deprecated, use `LabServerApp.blocked_extensions_uris` +# Default: '' +# c.LabServerApp.blacklist_uris = '' + +## A list of comma-separated URIs to get the blocked extensions list +# +# .. versionchanged:: 2.0.0 +# `LabServerApp.blacklist_uris` renamed to `blocked_extensions_uris` +# Default: '' +# c.LabServerApp.blocked_extensions_uris = '' + +## Whether to cache files on the server. This should be `True` except in dev +# mode. +# Default: True +# c.LabServerApp.cache_files = True + +## Full path of a config file. +# See also: JupyterApp.config_file +# c.LabServerApp.config_file = '' + +## Specify a config file to load. +# See also: JupyterApp.config_file_name +# c.LabServerApp.config_file_name = '' + +## Extra paths to look for federated JupyterLab extensions +# Default: [] +# c.LabServerApp.extra_labextensions_path = [] + +## Generate default config file. +# See also: JupyterApp.generate_config +# c.LabServerApp.generate_config = False + +## Handlers appended to the server. +# See also: ExtensionApp.handlers +# c.LabServerApp.handlers = [] + +## Options to pass to the jinja2 environment for this +# Default: {} +# c.LabServerApp.jinja2_options = {} + +## The standard paths to look in for federated JupyterLab extensions +# Default: [] +# c.LabServerApp.labextensions_path = [] + +## The url for federated JupyterLab extensions +# Default: '' +# c.LabServerApp.labextensions_url = '' + +## The interval delay in seconds to refresh the lists +# Default: 3600 +# c.LabServerApp.listings_refresh_seconds = 3600 + +## The optional kwargs to use for the listings HTTP requests as +# described on https://2.python-requests.org/en/v2.7.0/api/#requests.request +# Default: {} +# c.LabServerApp.listings_request_options = {} + +## The listings url. +# Default: '' +# c.LabServerApp.listings_url = '' + +## The date format used by logging formatters for %(asctime)s +# See also: Application.log_datefmt +# c.LabServerApp.log_datefmt = '%Y-%m-%d %H:%M:%S' + +## The Logging format template +# See also: Application.log_format +# c.LabServerApp.log_format = '[%(name)s]%(highlevel)s %(message)s' + +## Set the log level by value or name. +# See also: Application.log_level +# c.LabServerApp.log_level = 30 + +## +# See also: Application.logging_config +# c.LabServerApp.logging_config = {} + +## Whether a notebook should start a kernel automatically. +# Default: True +# c.LabServerApp.notebook_starts_kernel = True + +## Whether to open in a browser after starting. +# See also: ExtensionApp.open_browser +# c.LabServerApp.open_browser = False + +## The optional location of the settings schemas directory. If given, a handler +# will be added for settings. +# Default: '' +# c.LabServerApp.schemas_dir = '' + +## Settings that will passed to the server. +# See also: ExtensionApp.settings +# c.LabServerApp.settings = {} + +## The url path of the settings handler. +# Default: '' +# c.LabServerApp.settings_url = '' + +## Instead of starting the Application, dump configuration to stdout +# See also: Application.show_config +# c.LabServerApp.show_config = False + +## Instead of starting the Application, dump configuration to stdout (as JSON) +# See also: Application.show_config_json +# c.LabServerApp.show_config_json = False + +## The optional location of local static files. If given, a static file handler +# will be added. +# Default: '' +# c.LabServerApp.static_dir = '' + +## paths to search for serving static files. +# See also: ExtensionApp.static_paths +# c.LabServerApp.static_paths = [] + +## Url where the static assets for the extension are served. +# See also: ExtensionApp.static_url_prefix +# c.LabServerApp.static_url_prefix = '' + +## Paths to search for serving jinja templates. +# See also: ExtensionApp.template_paths +# c.LabServerApp.template_paths = [] + +## The application templates directory. +# Default: '' +# c.LabServerApp.templates_dir = '' + +## The optional location of the themes directory. If given, a handler will be +# added for themes. +# Default: '' +# c.LabServerApp.themes_dir = '' + +## The theme url. +# Default: '' +# c.LabServerApp.themes_url = '' + +## The url path of the translations handler. +# Default: '' +# c.LabServerApp.translations_api_url = '' + +## The url path of the tree handler. +# Default: '' +# c.LabServerApp.tree_url = '' + +## The optional location of the user settings directory. +# Default: '' +# c.LabServerApp.user_settings_dir = '' + +## Deprecated, use `LabServerApp.allowed_extensions_uris` +# Default: '' +# c.LabServerApp.whitelist_uris = '' + +## The url path of the workspaces API. +# Default: '' +# c.LabServerApp.workspaces_api_url = '' + +## The optional location of the saved workspaces directory. If given, a handler +# will be added for workspaces. +# Default: '' +# c.LabServerApp.workspaces_dir = '' + +#------------------------------------------------------------------------------ +# LabApp(LabServerApp) configuration +#------------------------------------------------------------------------------ +## +# See also: LabServerApp.allowed_extensions_uris +# c.LabApp.allowed_extensions_uris = '' + +## Answer yes to any prompts. +# See also: JupyterApp.answer_yes +# c.LabApp.answer_yes = False + +## The app directory to launch JupyterLab from. +# Default: None +# c.LabApp.app_dir = None + +## The application settings directory. +# Default: '' +# c.LabApp.app_settings_dir = '' + +## The url path for the application. +# Default: '/lab' +# c.LabApp.app_url = '/lab' + +## Deprecated, use `LabServerApp.blocked_extensions_uris` +# See also: LabServerApp.blacklist_uris +# c.LabApp.blacklist_uris = '' + +## +# See also: LabServerApp.blocked_extensions_uris +# c.LabApp.blocked_extensions_uris = '' + +## Whether to cache files on the server. This should be `True` except in dev +# mode. +# Default: True +# c.LabApp.cache_files = True + +## A callable class that receives the current version at instantiation and +# calling it must return asynchronously a string indicating which version is +# available and how to install or None if no update is available. The string +# supports Markdown format. +# Default: 'jupyterlab.handlers.announcements.CheckForUpdate' +# c.LabApp.check_for_updates_class = 'jupyterlab.handlers.announcements.CheckForUpdate' + +## Whether to enable collaborative mode. +# Default: False +# c.LabApp.collaborative = False + +## Full path of a config file. +# See also: JupyterApp.config_file +# c.LabApp.config_file = '' + +## Specify a config file to load. +# See also: JupyterApp.config_file_name +# c.LabApp.config_file_name = '' + +## Whether to start the app in core mode. In this mode, JupyterLab +# will run using the JavaScript assets that are within the installed +# JupyterLab Python package. In core mode, third party extensions are disabled. +# The `--dev-mode` flag is an alias to this to be used when the Python package +# itself is installed in development mode (`pip install -e .`). +# Default: False +# c.LabApp.core_mode = False + +## The default URL to redirect to from `/` +# Default: '/lab' +c.LabApp.default_url = '/lab/tree/workshops/scipy2023/index.ipynb' + +## Whether to start the app in dev mode. Uses the unpublished local +# JavaScript packages in the `dev_mode` folder. In this case JupyterLab will +# show a red stripe at the top of the page. It can only be used if JupyterLab +# is installed as `pip install -e .`. +# Default: False +# c.LabApp.dev_mode = False + +## Whether to expose the global app instance to browser via window.jupyterlab +# Default: False +# c.LabApp.expose_app_in_browser = False + +## Whether to load prebuilt extensions in dev mode. This may be +# useful to run and test prebuilt extensions in development installs of +# JupyterLab. APIs in a JupyterLab development install may be +# incompatible with published packages, so prebuilt extensions compiled +# against published packages may not work correctly. +# Default: False +# c.LabApp.extensions_in_dev_mode = False + +## Extra paths to look for federated JupyterLab extensions +# Default: [] +# c.LabApp.extra_labextensions_path = [] + +## Whether to skip loading styles for disabled prebuilt extensions. +# This will be the default behavior starting with JupyterLab 4.0 +# (and this flag will be removed). +# Default: False +# c.LabApp.future_skip_styles_for_disabled = False + +## Generate default config file. +# See also: JupyterApp.generate_config +# c.LabApp.generate_config = False + +## Handlers appended to the server. +# See also: ExtensionApp.handlers +# c.LabApp.handlers = [] + +## Options to pass to the jinja2 environment for this +# Default: {} +# c.LabApp.jinja2_options = {} + +## The standard paths to look in for federated JupyterLab extensions +# Default: [] +# c.LabApp.labextensions_path = [] + +## The url for federated JupyterLab extensions +# Default: '' +# c.LabApp.labextensions_url = '' + +## The interval delay in seconds to refresh the lists +# See also: LabServerApp.listings_refresh_seconds +# c.LabApp.listings_refresh_seconds = 3600 + +## The optional kwargs to use for the listings HTTP requests as +# described on https://2.python-requests.org/en/v2.7.0/api/#requests.request +# See also: LabServerApp.listings_request_options +# c.LabApp.listings_request_options = {} + +## The listings url. +# Default: '' +# c.LabApp.listings_url = '' + +## The date format used by logging formatters for %(asctime)s +# See also: Application.log_datefmt +# c.LabApp.log_datefmt = '%Y-%m-%d %H:%M:%S' + +## The Logging format template +# See also: Application.log_format +# c.LabApp.log_format = '[%(name)s]%(highlevel)s %(message)s' + +## Set the log level by value or name. +# See also: Application.log_level +# c.LabApp.log_level = 30 + +## +# See also: Application.logging_config +# c.LabApp.logging_config = {} + +## URL that serves news Atom feed; by default the JupyterLab organization +# announcements will be fetched. Set to None to turn off fetching announcements. +# Default: 'https://jupyterlab.github.io/assets/feed.xml' +# c.LabApp.news_url = 'https://jupyterlab.github.io/assets/feed.xml' + +## Whether a notebook should start a kernel automatically. +# Default: True +# c.LabApp.notebook_starts_kernel = True + +## Whether to open in a browser after starting. +# See also: ExtensionApp.open_browser +# c.LabApp.open_browser = False + +## The override url for static lab assets, typically a CDN. +# Default: '' +# c.LabApp.override_static_url = '' + +## The override url for static lab theme assets, typically a CDN. +# Default: '' +# c.LabApp.override_theme_url = '' + +## The optional location of the settings schemas directory. If given, a handler +# will be added for settings. +# Default: '' +# c.LabApp.schemas_dir = '' + +## Settings that will passed to the server. +# See also: ExtensionApp.settings +# c.LabApp.settings = {} + +## The url path of the settings handler. +# Default: '' +# c.LabApp.settings_url = '' + +## Instead of starting the Application, dump configuration to stdout +# See also: Application.show_config +# c.LabApp.show_config = False + +## Instead of starting the Application, dump configuration to stdout (as JSON) +# See also: Application.show_config_json +# c.LabApp.show_config_json = False + +## Splice source packages into app directory. +# Default: False +# c.LabApp.splice_source = False + +## The optional location of local static files. If given, a static file handler +# will be added. +# Default: '' +# c.LabApp.static_dir = '' + +## paths to search for serving static files. +# See also: ExtensionApp.static_paths +# c.LabApp.static_paths = [] + +## Url where the static assets for the extension are served. +# See also: ExtensionApp.static_url_prefix +# c.LabApp.static_url_prefix = '' + +## Paths to search for serving jinja templates. +# See also: ExtensionApp.template_paths +# c.LabApp.template_paths = [] + +## The application templates directory. +# Default: '' +# c.LabApp.templates_dir = '' + +## The optional location of the themes directory. If given, a handler will be +# added for themes. +# Default: '' +# c.LabApp.themes_dir = '' + +## The theme url. +# Default: '' +# c.LabApp.themes_url = '' + +## The url path of the translations handler. +# Default: '' +# c.LabApp.translations_api_url = '' + +## The url path of the tree handler. +# Default: '' +# c.LabApp.tree_url = '' + +## The directory for user settings. +# Default: '/Users/jovyan/.jupyter/lab/user-settings' +# c.LabApp.user_settings_dir = '/Users/jovyan/.jupyter/lab/user-settings' + +## Whether to serve the app in watch mode +# Default: False +# c.LabApp.watch = False + +## Deprecated, use `LabServerApp.allowed_extensions_uris` +# See also: LabServerApp.whitelist_uris +# c.LabApp.whitelist_uris = '' + +## The url path of the workspaces API. +# Default: '' +# c.LabApp.workspaces_api_url = '' + +## The directory for workspaces +# Default: '/Users/jovyan/.jupyter/lab/workspaces' +# c.LabApp.workspaces_dir = '/Users/jovyan/.jupyter/lab/workspaces' + +#------------------------------------------------------------------------------ +# ServerApp(JupyterApp) configuration +#------------------------------------------------------------------------------ +## The Jupyter Server application class. + +## Set the Access-Control-Allow-Credentials: true header +# Default: False +# c.ServerApp.allow_credentials = False + +## Set the Access-Control-Allow-Origin header +# +# Use '*' to allow any origin to access your server. +# +# Takes precedence over allow_origin_pat. +# Default: '' +# c.ServerApp.allow_origin = '' + +## Use a regular expression for the Access-Control-Allow-Origin header +# +# Requests from an origin matching the expression will get replies with: +# +# Access-Control-Allow-Origin: origin +# +# where `origin` is the origin of the request. +# +# Ignored if allow_origin is set. +# Default: '' +# c.ServerApp.allow_origin_pat = '' + +## DEPRECATED in 2.0. Use PasswordIdentityProvider.allow_password_change +# Default: True +# c.ServerApp.allow_password_change = True + +## Allow requests where the Host header doesn't point to a local server +# +# By default, requests get a 403 forbidden response if the 'Host' header +# shows that the browser thinks it's on a non-local domain. +# Setting this option to True disables this check. +# +# This protects against 'DNS rebinding' attacks, where a remote web server +# serves you a page and then changes its DNS to send later requests to a +# local IP, bypassing same-origin checks. +# +# Local IP addresses (such as 127.0.0.1 and ::1) are allowed as local, +# along with hostnames configured in local_hostnames. +# Default: False +# c.ServerApp.allow_remote_access = False + +## Whether to allow the user to run the server as root. +# Default: False +# c.ServerApp.allow_root = False + +## Answer yes to any prompts. +# See also: JupyterApp.answer_yes +# c.ServerApp.answer_yes = False + +## " +# Require authentication to access prometheus metrics. +# Default: True +# c.ServerApp.authenticate_prometheus = True + +## The authorizer class to use. +# Default: 'jupyter_server.auth.authorizer.AllowAllAuthorizer' +# c.ServerApp.authorizer_class = 'jupyter_server.auth.authorizer.AllowAllAuthorizer' + +## Reload the webapp when changes are made to any Python src files. +# Default: False +# c.ServerApp.autoreload = False + +## The base URL for the Jupyter server. +# +# Leading and trailing slashes can be omitted, +# and will automatically be added. +# Default: '/' +# c.ServerApp.base_url = '/' + +## Specify what command to use to invoke a web +# browser when starting the server. If not specified, the +# default browser will be determined by the `webbrowser` +# standard library module, which allows setting of the +# BROWSER environment variable to override it. +# Default: '' +# c.ServerApp.browser = '' + +## The full path to an SSL/TLS certificate file. +# Default: '' +# c.ServerApp.certfile = '' + +## The full path to a certificate authority certificate for SSL/TLS client +# authentication. +# Default: '' +# c.ServerApp.client_ca = '' + +## Full path of a config file. +# See also: JupyterApp.config_file +# c.ServerApp.config_file = '' + +## Specify a config file to load. +# See also: JupyterApp.config_file_name +# c.ServerApp.config_file_name = '' + +## The config manager class to use +# Default: 'jupyter_server.services.config.manager.ConfigManager' +# c.ServerApp.config_manager_class = 'jupyter_server.services.config.manager.ConfigManager' + +## The content manager class to use. +# Default: 'jupyter_server.services.contents.largefilemanager.AsyncLargeFileManager' +# c.ServerApp.contents_manager_class = 'jupyter_server.services.contents.largefilemanager.AsyncLargeFileManager' + +## DEPRECATED. Use IdentityProvider.cookie_options +# Default: {} +# c.ServerApp.cookie_options = {} + +## The random bytes used to secure cookies. +# By default this is a new random number every time you start the server. +# Set it to a value in a config file to enable logins to persist across server sessions. +# +# Note: Cookie secrets should be kept private, do not share config files with +# cookie_secret stored in plaintext (you can read the value from a file). +# Default: b'' +# c.ServerApp.cookie_secret = b'' + +## The file where the cookie secret is stored. +# Default: '' +# c.ServerApp.cookie_secret_file = '' + +## Override URL shown to users. +# +# Replace actual URL, including protocol, address, port and base URL, +# with the given value when displaying URL to the users. Do not change +# the actual connection URL. If authentication token is enabled, the +# token is added to the custom URL automatically. +# +# This option is intended to be used when the URL to display to the user +# cannot be determined reliably by the Jupyter server (proxified +# or containerized setups for example). +# Default: '' +# c.ServerApp.custom_display_url = '' + +## The default URL to redirect to from `/` +# Default: '/' +# c.ServerApp.default_url = '/' + +## Disable cross-site-request-forgery protection +# +# Jupyter server includes protection from cross-site request forgeries, +# requiring API requests to either: +# +# - originate from pages served by this server (validated with XSRF cookie and token), or +# - authenticate with a token +# +# Some anonymous compute resources still desire the ability to run code, +# completely without authentication. +# These services can disable all authentication and security checks, +# with the full knowledge of what that implies. +# Default: False +# c.ServerApp.disable_check_xsrf = False + +## handlers that should be loaded at higher priority than the default services +# Default: [] +# c.ServerApp.extra_services = [] + +## Extra paths to search for serving static files. +# +# This allows adding javascript/css to be available from the Jupyter server machine, +# or overriding individual files in the IPython +# Default: [] +# c.ServerApp.extra_static_paths = [] + +## Extra paths to search for serving jinja templates. +# +# Can be used to override templates from jupyter_server.templates. +# Default: [] +# c.ServerApp.extra_template_paths = [] + +## Open the named file when the application is launched. +# Default: '' +# c.ServerApp.file_to_run = '' + +## The URL prefix where files are opened directly. +# Default: 'notebooks' +# c.ServerApp.file_url_prefix = 'notebooks' + +## Generate default config file. +# See also: JupyterApp.generate_config +# c.ServerApp.generate_config = False + +## DEPRECATED. Use IdentityProvider.get_secure_cookie_kwargs +# Default: {} +# c.ServerApp.get_secure_cookie_kwargs = {} + +## The identity provider class to use. +# Default: 'jupyter_server.auth.identity.PasswordIdentityProvider' +# c.ServerApp.identity_provider_class = 'jupyter_server.auth.identity.PasswordIdentityProvider' + +## DEPRECATED. Use ZMQChannelsWebsocketConnection.iopub_data_rate_limit +# Default: 0.0 +# c.ServerApp.iopub_data_rate_limit = 0.0 + +## DEPRECATED. Use ZMQChannelsWebsocketConnection.iopub_msg_rate_limit +# Default: 0.0 +# c.ServerApp.iopub_msg_rate_limit = 0.0 + +## The IP address the Jupyter server will listen on. +# Default: 'localhost' +# c.ServerApp.ip = 'localhost' + +## Supply extra arguments that will be passed to Jinja environment. +# Default: {} +# c.ServerApp.jinja_environment_options = {} + +## Extra variables to supply to jinja templates when rendering. +# Default: {} +# c.ServerApp.jinja_template_vars = {} + +## Dict of Python modules to load as Jupyter server extensions.Entry values can +# be used to enable and disable the loading ofthe extensions. The extensions +# will be loaded in alphabetical order. +# Default: {} +# c.ServerApp.jpserver_extensions = {} + +## The kernel manager class to use. +# Default: 'jupyter_server.services.kernels.kernelmanager.MappingKernelManager' +# c.ServerApp.kernel_manager_class = 'jupyter_server.services.kernels.kernelmanager.MappingKernelManager' + +## The kernel spec manager class to use. Should be a subclass of +# `jupyter_client.kernelspec.KernelSpecManager`. +# +# The Api of KernelSpecManager is provisional and might change without warning +# between this version of Jupyter and the next stable one. +# Default: 'builtins.object' +# c.ServerApp.kernel_spec_manager_class = 'builtins.object' + +## The kernel websocket connection class to use. +# Default: 'jupyter_server.services.kernels.connection.channels.ZMQChannelsWebsocketConnection' +# c.ServerApp.kernel_websocket_connection_class = 'jupyter_server.services.kernels.connection.channels.ZMQChannelsWebsocketConnection' + +## DEPRECATED. Use ZMQChannelsWebsocketConnection.kernel_ws_protocol +# Default: '' +# c.ServerApp.kernel_ws_protocol = '' + +## The full path to a private key file for usage with SSL/TLS. +# Default: '' +# c.ServerApp.keyfile = '' + +## DEPRECATED. Use ZMQChannelsWebsocketConnection.limit_rate +# Default: False +# c.ServerApp.limit_rate = False + +## Hostnames to allow as local when allow_remote_access is False. +# +# Local IP addresses (such as 127.0.0.1 and ::1) are automatically accepted +# as local as well. +# Default: ['localhost'] +# c.ServerApp.local_hostnames = ['localhost'] + +## The date format used by logging formatters for %(asctime)s +# See also: Application.log_datefmt +# c.ServerApp.log_datefmt = '%Y-%m-%d %H:%M:%S' + +## The Logging format template +# See also: Application.log_format +# c.ServerApp.log_format = '[%(name)s]%(highlevel)s %(message)s' + +## Set the log level by value or name. +# See also: Application.log_level +# c.ServerApp.log_level = 30 + +## +# See also: Application.logging_config +# c.ServerApp.logging_config = {} + +## The login handler class to use. +# Default: 'jupyter_server.auth.login.LegacyLoginHandler' +# c.ServerApp.login_handler_class = 'jupyter_server.auth.login.LegacyLoginHandler' + +## The logout handler class to use. +# Default: 'jupyter_server.auth.logout.LogoutHandler' +# c.ServerApp.logout_handler_class = 'jupyter_server.auth.logout.LogoutHandler' + +## Sets the maximum allowed size of the client request body, specified in the +# Content-Length request header field. If the size in a request exceeds the +# configured value, a malformed HTTP message is returned to the client. +# +# Note: max_body_size is applied even in streaming mode. +# Default: 536870912 +# c.ServerApp.max_body_size = 536870912 + +## Gets or sets the maximum amount of memory, in bytes, that is allocated for use +# by the buffer manager. +# Default: 536870912 +# c.ServerApp.max_buffer_size = 536870912 + +## Gets or sets a lower bound on the open file handles process resource limit. +# This may need to be increased if you run into an OSError: [Errno 24] Too many +# open files. This is not applicable when running on Windows. +# Default: 0 +# c.ServerApp.min_open_files_limit = 0 + +## DEPRECATED, use root_dir. +# Default: '' +# c.ServerApp.notebook_dir = '' + +## Whether to open in a browser after starting. +# The specific browser used is platform dependent and +# determined by the python standard library `webbrowser` +# module, unless it is overridden using the --browser +# (ServerApp.browser) configuration option. +# Default: False +# c.ServerApp.open_browser = False + +## DEPRECATED in 2.0. Use PasswordIdentityProvider.hashed_password +# Default: '' +# c.ServerApp.password = '' + +## DEPRECATED in 2.0. Use PasswordIdentityProvider.password_required +# Default: False +# c.ServerApp.password_required = False + +## The port the server will listen on (env: JUPYTER_PORT). +# Default: 0 +# c.ServerApp.port = 0 + +## The number of additional ports to try if the specified port is not available +# (env: JUPYTER_PORT_RETRIES). +# Default: 50 +# c.ServerApp.port_retries = 50 + +## Preferred starting directory to use for notebooks and kernels. +# Default: '' +# c.ServerApp.preferred_dir = '' + +## DISABLED: use %pylab or %matplotlib in the notebook to enable matplotlib. +# Default: 'disabled' +# c.ServerApp.pylab = 'disabled' + +## If True, display controls to shut down the Jupyter server, such as menu items +# or buttons. +# Default: True +# c.ServerApp.quit_button = True + +## DEPRECATED. Use ZMQChannelsWebsocketConnection.rate_limit_window +# Default: 0.0 +# c.ServerApp.rate_limit_window = 0.0 + +## Reraise exceptions encountered loading server extensions? +# Default: False +# c.ServerApp.reraise_server_extension_failures = False + +## The directory to use for notebooks and kernels. +# Default: '' +# c.ServerApp.root_dir = '' + +## The session manager class to use. +# Default: 'builtins.object' +# c.ServerApp.session_manager_class = 'builtins.object' + +## Instead of starting the Application, dump configuration to stdout +# See also: Application.show_config +# c.ServerApp.show_config = False + +## Instead of starting the Application, dump configuration to stdout (as JSON) +# See also: Application.show_config_json +# c.ServerApp.show_config_json = False + +## Shut down the server after N seconds with no kernelsrunning and no activity. +# This can be used together with culling idle kernels +# (MappingKernelManager.cull_idle_timeout) to shutdown the Jupyter server when +# it's not in use. This is not precisely timed: it may shut down up to a minute +# later. 0 (the default) disables this automatic shutdown. +# Default: 0 +# c.ServerApp.shutdown_no_activity_timeout = 0 + +## The UNIX socket the Jupyter server will listen on. +# Default: '' +# c.ServerApp.sock = '' + +## The permissions mode for UNIX socket creation (default: 0600). +# Default: '0600' +# c.ServerApp.sock_mode = '0600' + +## Supply SSL options for the tornado HTTPServer. +# See the tornado docs for details. +# Default: {} +# c.ServerApp.ssl_options = {} + +## Supply overrides for terminado. Currently only supports "shell_command". +# Default: {} +# c.ServerApp.terminado_settings = {} + +## Set to False to disable terminals. +# +# This does *not* make the server more secure by itself. +# Anything the user can in a terminal, they can also do in a notebook. +# +# Terminals may also be automatically disabled if the terminado package +# is not available. +# Default: False +# c.ServerApp.terminals_enabled = False + +## DEPRECATED. Use IdentityProvider.token +# Default: '' +# c.ServerApp.token = '' + +## Supply overrides for the tornado.web.Application that the Jupyter server uses. +# Default: {} +# c.ServerApp.tornado_settings = {} + +## Whether to trust or not X-Scheme/X-Forwarded-Proto and X-Real-Ip/X-Forwarded- +# For headerssent by the upstream reverse proxy. Necessary if the proxy handles +# SSL +# Default: False +# c.ServerApp.trust_xheaders = False + +## Disable launching browser by redirect file +# For versions of notebook > 5.7.2, a security feature measure was added that +# prevented the authentication token used to launch the browser from being visible. +# This feature makes it difficult for other users on a multi-user system from +# running code in your Jupyter session as you. +# However, some environments (like Windows Subsystem for Linux (WSL) and Chromebooks), +# launching a browser using a redirect file can lead the browser failing to load. +# This is because of the difference in file structures/paths between the runtime and +# the browser. +# +# Disabling this setting to False will disable this behavior, allowing the browser +# to launch by using a URL and visible token (as before). +# Default: True +# c.ServerApp.use_redirect_file = True + +## Specify where to open the server on startup. This is the +# `new` argument passed to the standard library method `webbrowser.open`. +# The behaviour is not guaranteed, but depends on browser support. Valid +# values are: +# +# - 2 opens a new tab, +# - 1 opens a new window, +# - 0 opens in an existing window. +# +# See the `webbrowser.open` documentation for details. +# Default: 2 +# c.ServerApp.webbrowser_open_new = 2 + +## Set the tornado compression options for websocket connections. +# +# This value will be returned from +# :meth:`WebSocketHandler.get_compression_options`. None (default) will disable +# compression. A dict (even an empty one) will enable compression. +# +# See the tornado docs for WebSocketHandler.get_compression_options for details. +# Default: None +# c.ServerApp.websocket_compression_options = None + +## The base URL for websockets, +# if it differs from the HTTP server (hint: it almost certainly doesn't). +# +# Should be in the form of an HTTP origin: ws[s]://hostname[:port] +# Default: '' +# c.ServerApp.websocket_url = '' diff --git a/.devcontainer/scipy2023/devcontainer.json b/.devcontainer/scipy2023/devcontainer.json index 798d8418..7caf741e 100644 --- a/.devcontainer/scipy2023/devcontainer.json +++ b/.devcontainer/scipy2023/devcontainer.json @@ -1,7 +1,7 @@ { "build": { "dockerfile": "../Dockerfile", - "context": "../../conda" + "context": "../../.binder" }, "hostRequirements": { "cpus": 2 From 7cda838ae1f1b6ce0055118bdf0b80f749b71244 Mon Sep 17 00:00:00 2001 From: Landung 'Don' Setiawan Date: Thu, 22 Jun 2023 15:45:18 -0700 Subject: [PATCH 10/36] Fix context --- .devcontainer/scipy2023/devcontainer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.devcontainer/scipy2023/devcontainer.json b/.devcontainer/scipy2023/devcontainer.json index 7caf741e..f17ad92b 100644 --- a/.devcontainer/scipy2023/devcontainer.json +++ b/.devcontainer/scipy2023/devcontainer.json @@ -1,7 +1,7 @@ { "build": { "dockerfile": "../Dockerfile", - "context": "../../.binder" + "context": "../.." }, "hostRequirements": { "cpus": 2 From 179fe1f7a42ecd5b20612c982bb6eac94e62ce11 Mon Sep 17 00:00:00 2001 From: Landung 'Don' Setiawan Date: Thu, 22 Jun 2023 15:49:42 -0700 Subject: [PATCH 11/36] Remove jupyter lab config default url settings --- .binder/jupyter_lab_config.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.binder/jupyter_lab_config.py b/.binder/jupyter_lab_config.py index c32ddd8f..181e0cb4 100644 --- a/.binder/jupyter_lab_config.py +++ b/.binder/jupyter_lab_config.py @@ -461,7 +461,7 @@ ## The default URL to redirect to from `/` # Default: '/lab' -c.LabApp.default_url = '/lab/tree/workshops/scipy2023/index.ipynb' +# c.LabApp.default_url = '/lab/tree/workshops/scipy2023/index.ipynb' ## Whether to start the app in dev mode. Uses the unpublished local # JavaScript packages in the `dev_mode` folder. In this case JupyterLab will From 13bf3418809e9c8e9d628e24bb4b59fbb3eca416 Mon Sep 17 00:00:00 2001 From: Landung 'Don' Setiawan Date: Thu, 22 Jun 2023 15:53:35 -0700 Subject: [PATCH 12/36] Remove jb config.. doesn't quite work --- .binder/jupyter_lab_config.py | 1105 --------------------------------- 1 file changed, 1105 deletions(-) delete mode 100644 .binder/jupyter_lab_config.py diff --git a/.binder/jupyter_lab_config.py b/.binder/jupyter_lab_config.py deleted file mode 100644 index 181e0cb4..00000000 --- a/.binder/jupyter_lab_config.py +++ /dev/null @@ -1,1105 +0,0 @@ -# Configuration file for lab. - -c = get_config() #noqa - -#------------------------------------------------------------------------------ -# Application(SingletonConfigurable) configuration -#------------------------------------------------------------------------------ -## This is an application. - -## The date format used by logging formatters for %(asctime)s -# Default: '%Y-%m-%d %H:%M:%S' -# c.Application.log_datefmt = '%Y-%m-%d %H:%M:%S' - -## The Logging format template -# Default: '[%(name)s]%(highlevel)s %(message)s' -# c.Application.log_format = '[%(name)s]%(highlevel)s %(message)s' - -## Set the log level by value or name. -# Choices: any of [0, 10, 20, 30, 40, 50, 'DEBUG', 'INFO', 'WARN', 'ERROR', 'CRITICAL'] -# Default: 30 -# c.Application.log_level = 30 - -## Configure additional log handlers. -# -# The default stderr logs handler is configured by the log_level, log_datefmt -# and log_format settings. -# -# This configuration can be used to configure additional handlers (e.g. to -# output the log to a file) or for finer control over the default handlers. -# -# If provided this should be a logging configuration dictionary, for more -# information see: -# https://docs.python.org/3/library/logging.config.html#logging-config- -# dictschema -# -# This dictionary is merged with the base logging configuration which defines -# the following: -# -# * A logging formatter intended for interactive use called -# ``console``. -# * A logging handler that writes to stderr called -# ``console`` which uses the formatter ``console``. -# * A logger with the name of this application set to ``DEBUG`` -# level. -# -# This example adds a new handler that writes to a file: -# -# .. code-block:: python -# -# c.Application.logging_config = { -# 'handlers': { -# 'file': { -# 'class': 'logging.FileHandler', -# 'level': 'DEBUG', -# 'filename': '', -# } -# }, -# 'loggers': { -# '': { -# 'level': 'DEBUG', -# # NOTE: if you don't list the default "console" -# # handler here then it will be disabled -# 'handlers': ['console', 'file'], -# }, -# } -# } -# Default: {} -# c.Application.logging_config = {} - -## Instead of starting the Application, dump configuration to stdout -# Default: False -# c.Application.show_config = False - -## Instead of starting the Application, dump configuration to stdout (as JSON) -# Default: False -# c.Application.show_config_json = False - -#------------------------------------------------------------------------------ -# JupyterApp(Application) configuration -#------------------------------------------------------------------------------ -## Base class for Jupyter applications - -## Answer yes to any prompts. -# Default: False -# c.JupyterApp.answer_yes = False - -## Full path of a config file. -# Default: '' -# c.JupyterApp.config_file = '' - -## Specify a config file to load. -# Default: '' -# c.JupyterApp.config_file_name = '' - -## Generate default config file. -# Default: False -# c.JupyterApp.generate_config = False - -## The date format used by logging formatters for %(asctime)s -# See also: Application.log_datefmt -# c.JupyterApp.log_datefmt = '%Y-%m-%d %H:%M:%S' - -## The Logging format template -# See also: Application.log_format -# c.JupyterApp.log_format = '[%(name)s]%(highlevel)s %(message)s' - -## Set the log level by value or name. -# See also: Application.log_level -# c.JupyterApp.log_level = 30 - -## -# See also: Application.logging_config -# c.JupyterApp.logging_config = {} - -## Instead of starting the Application, dump configuration to stdout -# See also: Application.show_config -# c.JupyterApp.show_config = False - -## Instead of starting the Application, dump configuration to stdout (as JSON) -# See also: Application.show_config_json -# c.JupyterApp.show_config_json = False - -#------------------------------------------------------------------------------ -# ExtensionApp(JupyterApp) configuration -#------------------------------------------------------------------------------ -## Base class for configurable Jupyter Server Extension Applications. -# -# ExtensionApp subclasses can be initialized two ways: -# -# - Extension is listed as a jpserver_extension, and ServerApp calls -# its load_jupyter_server_extension classmethod. This is the -# classic way of loading a server extension. -# -# - Extension is launched directly by calling its `launch_instance` -# class method. This method can be set as a entry_point in -# the extensions setup.py. - -## Answer yes to any prompts. -# See also: JupyterApp.answer_yes -# c.ExtensionApp.answer_yes = False - -## Full path of a config file. -# See also: JupyterApp.config_file -# c.ExtensionApp.config_file = '' - -## Specify a config file to load. -# See also: JupyterApp.config_file_name -# c.ExtensionApp.config_file_name = '' - -# Default: '' -# c.ExtensionApp.default_url = '' - -## Generate default config file. -# See also: JupyterApp.generate_config -# c.ExtensionApp.generate_config = False - -## Handlers appended to the server. -# Default: [] -# c.ExtensionApp.handlers = [] - -## The date format used by logging formatters for %(asctime)s -# See also: Application.log_datefmt -# c.ExtensionApp.log_datefmt = '%Y-%m-%d %H:%M:%S' - -## The Logging format template -# See also: Application.log_format -# c.ExtensionApp.log_format = '[%(name)s]%(highlevel)s %(message)s' - -## Set the log level by value or name. -# See also: Application.log_level -# c.ExtensionApp.log_level = 30 - -## -# See also: Application.logging_config -# c.ExtensionApp.logging_config = {} - -## Whether to open in a browser after starting. -# The specific browser used is platform dependent and -# determined by the python standard library `webbrowser` -# module, unless it is overridden using the --browser -# (ServerApp.browser) configuration option. -# Default: False -# c.ExtensionApp.open_browser = False - -## Settings that will passed to the server. -# Default: {} -# c.ExtensionApp.settings = {} - -## Instead of starting the Application, dump configuration to stdout -# See also: Application.show_config -# c.ExtensionApp.show_config = False - -## Instead of starting the Application, dump configuration to stdout (as JSON) -# See also: Application.show_config_json -# c.ExtensionApp.show_config_json = False - -## paths to search for serving static files. -# -# This allows adding javascript/css to be available from the notebook server machine, -# or overriding individual files in the IPython -# Default: [] -# c.ExtensionApp.static_paths = [] - -## Url where the static assets for the extension are served. -# Default: '' -# c.ExtensionApp.static_url_prefix = '' - -## Paths to search for serving jinja templates. -# -# Can be used to override templates from notebook.templates. -# Default: [] -# c.ExtensionApp.template_paths = [] - -#------------------------------------------------------------------------------ -# LabServerApp(ExtensionApp) configuration -#------------------------------------------------------------------------------ -## A Lab Server Application that runs out-of-the-box - -## "A list of comma-separated URIs to get the allowed extensions list -# -# .. versionchanged:: 2.0.0 -# `LabServerApp.whitetlist_uris` renamed to `allowed_extensions_uris` -# Default: '' -# c.LabServerApp.allowed_extensions_uris = '' - -## Answer yes to any prompts. -# See also: JupyterApp.answer_yes -# c.LabServerApp.answer_yes = False - -## The application settings directory. -# Default: '' -# c.LabServerApp.app_settings_dir = '' - -## The url path for the application. -# Default: '/lab' -# c.LabServerApp.app_url = '/lab' - -## Deprecated, use `LabServerApp.blocked_extensions_uris` -# Default: '' -# c.LabServerApp.blacklist_uris = '' - -## A list of comma-separated URIs to get the blocked extensions list -# -# .. versionchanged:: 2.0.0 -# `LabServerApp.blacklist_uris` renamed to `blocked_extensions_uris` -# Default: '' -# c.LabServerApp.blocked_extensions_uris = '' - -## Whether to cache files on the server. This should be `True` except in dev -# mode. -# Default: True -# c.LabServerApp.cache_files = True - -## Full path of a config file. -# See also: JupyterApp.config_file -# c.LabServerApp.config_file = '' - -## Specify a config file to load. -# See also: JupyterApp.config_file_name -# c.LabServerApp.config_file_name = '' - -## Extra paths to look for federated JupyterLab extensions -# Default: [] -# c.LabServerApp.extra_labextensions_path = [] - -## Generate default config file. -# See also: JupyterApp.generate_config -# c.LabServerApp.generate_config = False - -## Handlers appended to the server. -# See also: ExtensionApp.handlers -# c.LabServerApp.handlers = [] - -## Options to pass to the jinja2 environment for this -# Default: {} -# c.LabServerApp.jinja2_options = {} - -## The standard paths to look in for federated JupyterLab extensions -# Default: [] -# c.LabServerApp.labextensions_path = [] - -## The url for federated JupyterLab extensions -# Default: '' -# c.LabServerApp.labextensions_url = '' - -## The interval delay in seconds to refresh the lists -# Default: 3600 -# c.LabServerApp.listings_refresh_seconds = 3600 - -## The optional kwargs to use for the listings HTTP requests as -# described on https://2.python-requests.org/en/v2.7.0/api/#requests.request -# Default: {} -# c.LabServerApp.listings_request_options = {} - -## The listings url. -# Default: '' -# c.LabServerApp.listings_url = '' - -## The date format used by logging formatters for %(asctime)s -# See also: Application.log_datefmt -# c.LabServerApp.log_datefmt = '%Y-%m-%d %H:%M:%S' - -## The Logging format template -# See also: Application.log_format -# c.LabServerApp.log_format = '[%(name)s]%(highlevel)s %(message)s' - -## Set the log level by value or name. -# See also: Application.log_level -# c.LabServerApp.log_level = 30 - -## -# See also: Application.logging_config -# c.LabServerApp.logging_config = {} - -## Whether a notebook should start a kernel automatically. -# Default: True -# c.LabServerApp.notebook_starts_kernel = True - -## Whether to open in a browser after starting. -# See also: ExtensionApp.open_browser -# c.LabServerApp.open_browser = False - -## The optional location of the settings schemas directory. If given, a handler -# will be added for settings. -# Default: '' -# c.LabServerApp.schemas_dir = '' - -## Settings that will passed to the server. -# See also: ExtensionApp.settings -# c.LabServerApp.settings = {} - -## The url path of the settings handler. -# Default: '' -# c.LabServerApp.settings_url = '' - -## Instead of starting the Application, dump configuration to stdout -# See also: Application.show_config -# c.LabServerApp.show_config = False - -## Instead of starting the Application, dump configuration to stdout (as JSON) -# See also: Application.show_config_json -# c.LabServerApp.show_config_json = False - -## The optional location of local static files. If given, a static file handler -# will be added. -# Default: '' -# c.LabServerApp.static_dir = '' - -## paths to search for serving static files. -# See also: ExtensionApp.static_paths -# c.LabServerApp.static_paths = [] - -## Url where the static assets for the extension are served. -# See also: ExtensionApp.static_url_prefix -# c.LabServerApp.static_url_prefix = '' - -## Paths to search for serving jinja templates. -# See also: ExtensionApp.template_paths -# c.LabServerApp.template_paths = [] - -## The application templates directory. -# Default: '' -# c.LabServerApp.templates_dir = '' - -## The optional location of the themes directory. If given, a handler will be -# added for themes. -# Default: '' -# c.LabServerApp.themes_dir = '' - -## The theme url. -# Default: '' -# c.LabServerApp.themes_url = '' - -## The url path of the translations handler. -# Default: '' -# c.LabServerApp.translations_api_url = '' - -## The url path of the tree handler. -# Default: '' -# c.LabServerApp.tree_url = '' - -## The optional location of the user settings directory. -# Default: '' -# c.LabServerApp.user_settings_dir = '' - -## Deprecated, use `LabServerApp.allowed_extensions_uris` -# Default: '' -# c.LabServerApp.whitelist_uris = '' - -## The url path of the workspaces API. -# Default: '' -# c.LabServerApp.workspaces_api_url = '' - -## The optional location of the saved workspaces directory. If given, a handler -# will be added for workspaces. -# Default: '' -# c.LabServerApp.workspaces_dir = '' - -#------------------------------------------------------------------------------ -# LabApp(LabServerApp) configuration -#------------------------------------------------------------------------------ -## -# See also: LabServerApp.allowed_extensions_uris -# c.LabApp.allowed_extensions_uris = '' - -## Answer yes to any prompts. -# See also: JupyterApp.answer_yes -# c.LabApp.answer_yes = False - -## The app directory to launch JupyterLab from. -# Default: None -# c.LabApp.app_dir = None - -## The application settings directory. -# Default: '' -# c.LabApp.app_settings_dir = '' - -## The url path for the application. -# Default: '/lab' -# c.LabApp.app_url = '/lab' - -## Deprecated, use `LabServerApp.blocked_extensions_uris` -# See also: LabServerApp.blacklist_uris -# c.LabApp.blacklist_uris = '' - -## -# See also: LabServerApp.blocked_extensions_uris -# c.LabApp.blocked_extensions_uris = '' - -## Whether to cache files on the server. This should be `True` except in dev -# mode. -# Default: True -# c.LabApp.cache_files = True - -## A callable class that receives the current version at instantiation and -# calling it must return asynchronously a string indicating which version is -# available and how to install or None if no update is available. The string -# supports Markdown format. -# Default: 'jupyterlab.handlers.announcements.CheckForUpdate' -# c.LabApp.check_for_updates_class = 'jupyterlab.handlers.announcements.CheckForUpdate' - -## Whether to enable collaborative mode. -# Default: False -# c.LabApp.collaborative = False - -## Full path of a config file. -# See also: JupyterApp.config_file -# c.LabApp.config_file = '' - -## Specify a config file to load. -# See also: JupyterApp.config_file_name -# c.LabApp.config_file_name = '' - -## Whether to start the app in core mode. In this mode, JupyterLab -# will run using the JavaScript assets that are within the installed -# JupyterLab Python package. In core mode, third party extensions are disabled. -# The `--dev-mode` flag is an alias to this to be used when the Python package -# itself is installed in development mode (`pip install -e .`). -# Default: False -# c.LabApp.core_mode = False - -## The default URL to redirect to from `/` -# Default: '/lab' -# c.LabApp.default_url = '/lab/tree/workshops/scipy2023/index.ipynb' - -## Whether to start the app in dev mode. Uses the unpublished local -# JavaScript packages in the `dev_mode` folder. In this case JupyterLab will -# show a red stripe at the top of the page. It can only be used if JupyterLab -# is installed as `pip install -e .`. -# Default: False -# c.LabApp.dev_mode = False - -## Whether to expose the global app instance to browser via window.jupyterlab -# Default: False -# c.LabApp.expose_app_in_browser = False - -## Whether to load prebuilt extensions in dev mode. This may be -# useful to run and test prebuilt extensions in development installs of -# JupyterLab. APIs in a JupyterLab development install may be -# incompatible with published packages, so prebuilt extensions compiled -# against published packages may not work correctly. -# Default: False -# c.LabApp.extensions_in_dev_mode = False - -## Extra paths to look for federated JupyterLab extensions -# Default: [] -# c.LabApp.extra_labextensions_path = [] - -## Whether to skip loading styles for disabled prebuilt extensions. -# This will be the default behavior starting with JupyterLab 4.0 -# (and this flag will be removed). -# Default: False -# c.LabApp.future_skip_styles_for_disabled = False - -## Generate default config file. -# See also: JupyterApp.generate_config -# c.LabApp.generate_config = False - -## Handlers appended to the server. -# See also: ExtensionApp.handlers -# c.LabApp.handlers = [] - -## Options to pass to the jinja2 environment for this -# Default: {} -# c.LabApp.jinja2_options = {} - -## The standard paths to look in for federated JupyterLab extensions -# Default: [] -# c.LabApp.labextensions_path = [] - -## The url for federated JupyterLab extensions -# Default: '' -# c.LabApp.labextensions_url = '' - -## The interval delay in seconds to refresh the lists -# See also: LabServerApp.listings_refresh_seconds -# c.LabApp.listings_refresh_seconds = 3600 - -## The optional kwargs to use for the listings HTTP requests as -# described on https://2.python-requests.org/en/v2.7.0/api/#requests.request -# See also: LabServerApp.listings_request_options -# c.LabApp.listings_request_options = {} - -## The listings url. -# Default: '' -# c.LabApp.listings_url = '' - -## The date format used by logging formatters for %(asctime)s -# See also: Application.log_datefmt -# c.LabApp.log_datefmt = '%Y-%m-%d %H:%M:%S' - -## The Logging format template -# See also: Application.log_format -# c.LabApp.log_format = '[%(name)s]%(highlevel)s %(message)s' - -## Set the log level by value or name. -# See also: Application.log_level -# c.LabApp.log_level = 30 - -## -# See also: Application.logging_config -# c.LabApp.logging_config = {} - -## URL that serves news Atom feed; by default the JupyterLab organization -# announcements will be fetched. Set to None to turn off fetching announcements. -# Default: 'https://jupyterlab.github.io/assets/feed.xml' -# c.LabApp.news_url = 'https://jupyterlab.github.io/assets/feed.xml' - -## Whether a notebook should start a kernel automatically. -# Default: True -# c.LabApp.notebook_starts_kernel = True - -## Whether to open in a browser after starting. -# See also: ExtensionApp.open_browser -# c.LabApp.open_browser = False - -## The override url for static lab assets, typically a CDN. -# Default: '' -# c.LabApp.override_static_url = '' - -## The override url for static lab theme assets, typically a CDN. -# Default: '' -# c.LabApp.override_theme_url = '' - -## The optional location of the settings schemas directory. If given, a handler -# will be added for settings. -# Default: '' -# c.LabApp.schemas_dir = '' - -## Settings that will passed to the server. -# See also: ExtensionApp.settings -# c.LabApp.settings = {} - -## The url path of the settings handler. -# Default: '' -# c.LabApp.settings_url = '' - -## Instead of starting the Application, dump configuration to stdout -# See also: Application.show_config -# c.LabApp.show_config = False - -## Instead of starting the Application, dump configuration to stdout (as JSON) -# See also: Application.show_config_json -# c.LabApp.show_config_json = False - -## Splice source packages into app directory. -# Default: False -# c.LabApp.splice_source = False - -## The optional location of local static files. If given, a static file handler -# will be added. -# Default: '' -# c.LabApp.static_dir = '' - -## paths to search for serving static files. -# See also: ExtensionApp.static_paths -# c.LabApp.static_paths = [] - -## Url where the static assets for the extension are served. -# See also: ExtensionApp.static_url_prefix -# c.LabApp.static_url_prefix = '' - -## Paths to search for serving jinja templates. -# See also: ExtensionApp.template_paths -# c.LabApp.template_paths = [] - -## The application templates directory. -# Default: '' -# c.LabApp.templates_dir = '' - -## The optional location of the themes directory. If given, a handler will be -# added for themes. -# Default: '' -# c.LabApp.themes_dir = '' - -## The theme url. -# Default: '' -# c.LabApp.themes_url = '' - -## The url path of the translations handler. -# Default: '' -# c.LabApp.translations_api_url = '' - -## The url path of the tree handler. -# Default: '' -# c.LabApp.tree_url = '' - -## The directory for user settings. -# Default: '/Users/jovyan/.jupyter/lab/user-settings' -# c.LabApp.user_settings_dir = '/Users/jovyan/.jupyter/lab/user-settings' - -## Whether to serve the app in watch mode -# Default: False -# c.LabApp.watch = False - -## Deprecated, use `LabServerApp.allowed_extensions_uris` -# See also: LabServerApp.whitelist_uris -# c.LabApp.whitelist_uris = '' - -## The url path of the workspaces API. -# Default: '' -# c.LabApp.workspaces_api_url = '' - -## The directory for workspaces -# Default: '/Users/jovyan/.jupyter/lab/workspaces' -# c.LabApp.workspaces_dir = '/Users/jovyan/.jupyter/lab/workspaces' - -#------------------------------------------------------------------------------ -# ServerApp(JupyterApp) configuration -#------------------------------------------------------------------------------ -## The Jupyter Server application class. - -## Set the Access-Control-Allow-Credentials: true header -# Default: False -# c.ServerApp.allow_credentials = False - -## Set the Access-Control-Allow-Origin header -# -# Use '*' to allow any origin to access your server. -# -# Takes precedence over allow_origin_pat. -# Default: '' -# c.ServerApp.allow_origin = '' - -## Use a regular expression for the Access-Control-Allow-Origin header -# -# Requests from an origin matching the expression will get replies with: -# -# Access-Control-Allow-Origin: origin -# -# where `origin` is the origin of the request. -# -# Ignored if allow_origin is set. -# Default: '' -# c.ServerApp.allow_origin_pat = '' - -## DEPRECATED in 2.0. Use PasswordIdentityProvider.allow_password_change -# Default: True -# c.ServerApp.allow_password_change = True - -## Allow requests where the Host header doesn't point to a local server -# -# By default, requests get a 403 forbidden response if the 'Host' header -# shows that the browser thinks it's on a non-local domain. -# Setting this option to True disables this check. -# -# This protects against 'DNS rebinding' attacks, where a remote web server -# serves you a page and then changes its DNS to send later requests to a -# local IP, bypassing same-origin checks. -# -# Local IP addresses (such as 127.0.0.1 and ::1) are allowed as local, -# along with hostnames configured in local_hostnames. -# Default: False -# c.ServerApp.allow_remote_access = False - -## Whether to allow the user to run the server as root. -# Default: False -# c.ServerApp.allow_root = False - -## Answer yes to any prompts. -# See also: JupyterApp.answer_yes -# c.ServerApp.answer_yes = False - -## " -# Require authentication to access prometheus metrics. -# Default: True -# c.ServerApp.authenticate_prometheus = True - -## The authorizer class to use. -# Default: 'jupyter_server.auth.authorizer.AllowAllAuthorizer' -# c.ServerApp.authorizer_class = 'jupyter_server.auth.authorizer.AllowAllAuthorizer' - -## Reload the webapp when changes are made to any Python src files. -# Default: False -# c.ServerApp.autoreload = False - -## The base URL for the Jupyter server. -# -# Leading and trailing slashes can be omitted, -# and will automatically be added. -# Default: '/' -# c.ServerApp.base_url = '/' - -## Specify what command to use to invoke a web -# browser when starting the server. If not specified, the -# default browser will be determined by the `webbrowser` -# standard library module, which allows setting of the -# BROWSER environment variable to override it. -# Default: '' -# c.ServerApp.browser = '' - -## The full path to an SSL/TLS certificate file. -# Default: '' -# c.ServerApp.certfile = '' - -## The full path to a certificate authority certificate for SSL/TLS client -# authentication. -# Default: '' -# c.ServerApp.client_ca = '' - -## Full path of a config file. -# See also: JupyterApp.config_file -# c.ServerApp.config_file = '' - -## Specify a config file to load. -# See also: JupyterApp.config_file_name -# c.ServerApp.config_file_name = '' - -## The config manager class to use -# Default: 'jupyter_server.services.config.manager.ConfigManager' -# c.ServerApp.config_manager_class = 'jupyter_server.services.config.manager.ConfigManager' - -## The content manager class to use. -# Default: 'jupyter_server.services.contents.largefilemanager.AsyncLargeFileManager' -# c.ServerApp.contents_manager_class = 'jupyter_server.services.contents.largefilemanager.AsyncLargeFileManager' - -## DEPRECATED. Use IdentityProvider.cookie_options -# Default: {} -# c.ServerApp.cookie_options = {} - -## The random bytes used to secure cookies. -# By default this is a new random number every time you start the server. -# Set it to a value in a config file to enable logins to persist across server sessions. -# -# Note: Cookie secrets should be kept private, do not share config files with -# cookie_secret stored in plaintext (you can read the value from a file). -# Default: b'' -# c.ServerApp.cookie_secret = b'' - -## The file where the cookie secret is stored. -# Default: '' -# c.ServerApp.cookie_secret_file = '' - -## Override URL shown to users. -# -# Replace actual URL, including protocol, address, port and base URL, -# with the given value when displaying URL to the users. Do not change -# the actual connection URL. If authentication token is enabled, the -# token is added to the custom URL automatically. -# -# This option is intended to be used when the URL to display to the user -# cannot be determined reliably by the Jupyter server (proxified -# or containerized setups for example). -# Default: '' -# c.ServerApp.custom_display_url = '' - -## The default URL to redirect to from `/` -# Default: '/' -# c.ServerApp.default_url = '/' - -## Disable cross-site-request-forgery protection -# -# Jupyter server includes protection from cross-site request forgeries, -# requiring API requests to either: -# -# - originate from pages served by this server (validated with XSRF cookie and token), or -# - authenticate with a token -# -# Some anonymous compute resources still desire the ability to run code, -# completely without authentication. -# These services can disable all authentication and security checks, -# with the full knowledge of what that implies. -# Default: False -# c.ServerApp.disable_check_xsrf = False - -## handlers that should be loaded at higher priority than the default services -# Default: [] -# c.ServerApp.extra_services = [] - -## Extra paths to search for serving static files. -# -# This allows adding javascript/css to be available from the Jupyter server machine, -# or overriding individual files in the IPython -# Default: [] -# c.ServerApp.extra_static_paths = [] - -## Extra paths to search for serving jinja templates. -# -# Can be used to override templates from jupyter_server.templates. -# Default: [] -# c.ServerApp.extra_template_paths = [] - -## Open the named file when the application is launched. -# Default: '' -# c.ServerApp.file_to_run = '' - -## The URL prefix where files are opened directly. -# Default: 'notebooks' -# c.ServerApp.file_url_prefix = 'notebooks' - -## Generate default config file. -# See also: JupyterApp.generate_config -# c.ServerApp.generate_config = False - -## DEPRECATED. Use IdentityProvider.get_secure_cookie_kwargs -# Default: {} -# c.ServerApp.get_secure_cookie_kwargs = {} - -## The identity provider class to use. -# Default: 'jupyter_server.auth.identity.PasswordIdentityProvider' -# c.ServerApp.identity_provider_class = 'jupyter_server.auth.identity.PasswordIdentityProvider' - -## DEPRECATED. Use ZMQChannelsWebsocketConnection.iopub_data_rate_limit -# Default: 0.0 -# c.ServerApp.iopub_data_rate_limit = 0.0 - -## DEPRECATED. Use ZMQChannelsWebsocketConnection.iopub_msg_rate_limit -# Default: 0.0 -# c.ServerApp.iopub_msg_rate_limit = 0.0 - -## The IP address the Jupyter server will listen on. -# Default: 'localhost' -# c.ServerApp.ip = 'localhost' - -## Supply extra arguments that will be passed to Jinja environment. -# Default: {} -# c.ServerApp.jinja_environment_options = {} - -## Extra variables to supply to jinja templates when rendering. -# Default: {} -# c.ServerApp.jinja_template_vars = {} - -## Dict of Python modules to load as Jupyter server extensions.Entry values can -# be used to enable and disable the loading ofthe extensions. The extensions -# will be loaded in alphabetical order. -# Default: {} -# c.ServerApp.jpserver_extensions = {} - -## The kernel manager class to use. -# Default: 'jupyter_server.services.kernels.kernelmanager.MappingKernelManager' -# c.ServerApp.kernel_manager_class = 'jupyter_server.services.kernels.kernelmanager.MappingKernelManager' - -## The kernel spec manager class to use. Should be a subclass of -# `jupyter_client.kernelspec.KernelSpecManager`. -# -# The Api of KernelSpecManager is provisional and might change without warning -# between this version of Jupyter and the next stable one. -# Default: 'builtins.object' -# c.ServerApp.kernel_spec_manager_class = 'builtins.object' - -## The kernel websocket connection class to use. -# Default: 'jupyter_server.services.kernels.connection.channels.ZMQChannelsWebsocketConnection' -# c.ServerApp.kernel_websocket_connection_class = 'jupyter_server.services.kernels.connection.channels.ZMQChannelsWebsocketConnection' - -## DEPRECATED. Use ZMQChannelsWebsocketConnection.kernel_ws_protocol -# Default: '' -# c.ServerApp.kernel_ws_protocol = '' - -## The full path to a private key file for usage with SSL/TLS. -# Default: '' -# c.ServerApp.keyfile = '' - -## DEPRECATED. Use ZMQChannelsWebsocketConnection.limit_rate -# Default: False -# c.ServerApp.limit_rate = False - -## Hostnames to allow as local when allow_remote_access is False. -# -# Local IP addresses (such as 127.0.0.1 and ::1) are automatically accepted -# as local as well. -# Default: ['localhost'] -# c.ServerApp.local_hostnames = ['localhost'] - -## The date format used by logging formatters for %(asctime)s -# See also: Application.log_datefmt -# c.ServerApp.log_datefmt = '%Y-%m-%d %H:%M:%S' - -## The Logging format template -# See also: Application.log_format -# c.ServerApp.log_format = '[%(name)s]%(highlevel)s %(message)s' - -## Set the log level by value or name. -# See also: Application.log_level -# c.ServerApp.log_level = 30 - -## -# See also: Application.logging_config -# c.ServerApp.logging_config = {} - -## The login handler class to use. -# Default: 'jupyter_server.auth.login.LegacyLoginHandler' -# c.ServerApp.login_handler_class = 'jupyter_server.auth.login.LegacyLoginHandler' - -## The logout handler class to use. -# Default: 'jupyter_server.auth.logout.LogoutHandler' -# c.ServerApp.logout_handler_class = 'jupyter_server.auth.logout.LogoutHandler' - -## Sets the maximum allowed size of the client request body, specified in the -# Content-Length request header field. If the size in a request exceeds the -# configured value, a malformed HTTP message is returned to the client. -# -# Note: max_body_size is applied even in streaming mode. -# Default: 536870912 -# c.ServerApp.max_body_size = 536870912 - -## Gets or sets the maximum amount of memory, in bytes, that is allocated for use -# by the buffer manager. -# Default: 536870912 -# c.ServerApp.max_buffer_size = 536870912 - -## Gets or sets a lower bound on the open file handles process resource limit. -# This may need to be increased if you run into an OSError: [Errno 24] Too many -# open files. This is not applicable when running on Windows. -# Default: 0 -# c.ServerApp.min_open_files_limit = 0 - -## DEPRECATED, use root_dir. -# Default: '' -# c.ServerApp.notebook_dir = '' - -## Whether to open in a browser after starting. -# The specific browser used is platform dependent and -# determined by the python standard library `webbrowser` -# module, unless it is overridden using the --browser -# (ServerApp.browser) configuration option. -# Default: False -# c.ServerApp.open_browser = False - -## DEPRECATED in 2.0. Use PasswordIdentityProvider.hashed_password -# Default: '' -# c.ServerApp.password = '' - -## DEPRECATED in 2.0. Use PasswordIdentityProvider.password_required -# Default: False -# c.ServerApp.password_required = False - -## The port the server will listen on (env: JUPYTER_PORT). -# Default: 0 -# c.ServerApp.port = 0 - -## The number of additional ports to try if the specified port is not available -# (env: JUPYTER_PORT_RETRIES). -# Default: 50 -# c.ServerApp.port_retries = 50 - -## Preferred starting directory to use for notebooks and kernels. -# Default: '' -# c.ServerApp.preferred_dir = '' - -## DISABLED: use %pylab or %matplotlib in the notebook to enable matplotlib. -# Default: 'disabled' -# c.ServerApp.pylab = 'disabled' - -## If True, display controls to shut down the Jupyter server, such as menu items -# or buttons. -# Default: True -# c.ServerApp.quit_button = True - -## DEPRECATED. Use ZMQChannelsWebsocketConnection.rate_limit_window -# Default: 0.0 -# c.ServerApp.rate_limit_window = 0.0 - -## Reraise exceptions encountered loading server extensions? -# Default: False -# c.ServerApp.reraise_server_extension_failures = False - -## The directory to use for notebooks and kernels. -# Default: '' -# c.ServerApp.root_dir = '' - -## The session manager class to use. -# Default: 'builtins.object' -# c.ServerApp.session_manager_class = 'builtins.object' - -## Instead of starting the Application, dump configuration to stdout -# See also: Application.show_config -# c.ServerApp.show_config = False - -## Instead of starting the Application, dump configuration to stdout (as JSON) -# See also: Application.show_config_json -# c.ServerApp.show_config_json = False - -## Shut down the server after N seconds with no kernelsrunning and no activity. -# This can be used together with culling idle kernels -# (MappingKernelManager.cull_idle_timeout) to shutdown the Jupyter server when -# it's not in use. This is not precisely timed: it may shut down up to a minute -# later. 0 (the default) disables this automatic shutdown. -# Default: 0 -# c.ServerApp.shutdown_no_activity_timeout = 0 - -## The UNIX socket the Jupyter server will listen on. -# Default: '' -# c.ServerApp.sock = '' - -## The permissions mode for UNIX socket creation (default: 0600). -# Default: '0600' -# c.ServerApp.sock_mode = '0600' - -## Supply SSL options for the tornado HTTPServer. -# See the tornado docs for details. -# Default: {} -# c.ServerApp.ssl_options = {} - -## Supply overrides for terminado. Currently only supports "shell_command". -# Default: {} -# c.ServerApp.terminado_settings = {} - -## Set to False to disable terminals. -# -# This does *not* make the server more secure by itself. -# Anything the user can in a terminal, they can also do in a notebook. -# -# Terminals may also be automatically disabled if the terminado package -# is not available. -# Default: False -# c.ServerApp.terminals_enabled = False - -## DEPRECATED. Use IdentityProvider.token -# Default: '' -# c.ServerApp.token = '' - -## Supply overrides for the tornado.web.Application that the Jupyter server uses. -# Default: {} -# c.ServerApp.tornado_settings = {} - -## Whether to trust or not X-Scheme/X-Forwarded-Proto and X-Real-Ip/X-Forwarded- -# For headerssent by the upstream reverse proxy. Necessary if the proxy handles -# SSL -# Default: False -# c.ServerApp.trust_xheaders = False - -## Disable launching browser by redirect file -# For versions of notebook > 5.7.2, a security feature measure was added that -# prevented the authentication token used to launch the browser from being visible. -# This feature makes it difficult for other users on a multi-user system from -# running code in your Jupyter session as you. -# However, some environments (like Windows Subsystem for Linux (WSL) and Chromebooks), -# launching a browser using a redirect file can lead the browser failing to load. -# This is because of the difference in file structures/paths between the runtime and -# the browser. -# -# Disabling this setting to False will disable this behavior, allowing the browser -# to launch by using a URL and visible token (as before). -# Default: True -# c.ServerApp.use_redirect_file = True - -## Specify where to open the server on startup. This is the -# `new` argument passed to the standard library method `webbrowser.open`. -# The behaviour is not guaranteed, but depends on browser support. Valid -# values are: -# -# - 2 opens a new tab, -# - 1 opens a new window, -# - 0 opens in an existing window. -# -# See the `webbrowser.open` documentation for details. -# Default: 2 -# c.ServerApp.webbrowser_open_new = 2 - -## Set the tornado compression options for websocket connections. -# -# This value will be returned from -# :meth:`WebSocketHandler.get_compression_options`. None (default) will disable -# compression. A dict (even an empty one) will enable compression. -# -# See the tornado docs for WebSocketHandler.get_compression_options for details. -# Default: None -# c.ServerApp.websocket_compression_options = None - -## The base URL for websockets, -# if it differs from the HTTP server (hint: it almost certainly doesn't). -# -# Should be in the form of an HTTP origin: ws[s]://hostname[:port] -# Default: '' -# c.ServerApp.websocket_url = '' From eb575525bad58fe48236e34fcd45ed6eeb32048e Mon Sep 17 00:00:00 2001 From: Landung 'Don' Setiawan Date: Thu, 22 Jun 2023 16:01:29 -0700 Subject: [PATCH 13/36] Move configs to conda/binder --- .devcontainer/scipy2023/devcontainer.json | 2 +- {.binder => conda/binder}/apt.txt | 0 conda/binder/jupyter_lab_config.py | 1105 +++++++++++++++++++++ 3 files changed, 1106 insertions(+), 1 deletion(-) rename {.binder => conda/binder}/apt.txt (100%) create mode 100644 conda/binder/jupyter_lab_config.py diff --git a/.devcontainer/scipy2023/devcontainer.json b/.devcontainer/scipy2023/devcontainer.json index f17ad92b..798d8418 100644 --- a/.devcontainer/scipy2023/devcontainer.json +++ b/.devcontainer/scipy2023/devcontainer.json @@ -1,7 +1,7 @@ { "build": { "dockerfile": "../Dockerfile", - "context": "../.." + "context": "../../conda" }, "hostRequirements": { "cpus": 2 diff --git a/.binder/apt.txt b/conda/binder/apt.txt similarity index 100% rename from .binder/apt.txt rename to conda/binder/apt.txt diff --git a/conda/binder/jupyter_lab_config.py b/conda/binder/jupyter_lab_config.py new file mode 100644 index 00000000..0494bb61 --- /dev/null +++ b/conda/binder/jupyter_lab_config.py @@ -0,0 +1,1105 @@ +# Configuration file for lab. + +c = get_config() #noqa + +#------------------------------------------------------------------------------ +# Application(SingletonConfigurable) configuration +#------------------------------------------------------------------------------ +## This is an application. + +## The date format used by logging formatters for %(asctime)s +# Default: '%Y-%m-%d %H:%M:%S' +# c.Application.log_datefmt = '%Y-%m-%d %H:%M:%S' + +## The Logging format template +# Default: '[%(name)s]%(highlevel)s %(message)s' +# c.Application.log_format = '[%(name)s]%(highlevel)s %(message)s' + +## Set the log level by value or name. +# Choices: any of [0, 10, 20, 30, 40, 50, 'DEBUG', 'INFO', 'WARN', 'ERROR', 'CRITICAL'] +# Default: 30 +# c.Application.log_level = 30 + +## Configure additional log handlers. +# +# The default stderr logs handler is configured by the log_level, log_datefmt +# and log_format settings. +# +# This configuration can be used to configure additional handlers (e.g. to +# output the log to a file) or for finer control over the default handlers. +# +# If provided this should be a logging configuration dictionary, for more +# information see: +# https://docs.python.org/3/library/logging.config.html#logging-config- +# dictschema +# +# This dictionary is merged with the base logging configuration which defines +# the following: +# +# * A logging formatter intended for interactive use called +# ``console``. +# * A logging handler that writes to stderr called +# ``console`` which uses the formatter ``console``. +# * A logger with the name of this application set to ``DEBUG`` +# level. +# +# This example adds a new handler that writes to a file: +# +# .. code-block:: python +# +# c.Application.logging_config = { +# 'handlers': { +# 'file': { +# 'class': 'logging.FileHandler', +# 'level': 'DEBUG', +# 'filename': '', +# } +# }, +# 'loggers': { +# '': { +# 'level': 'DEBUG', +# # NOTE: if you don't list the default "console" +# # handler here then it will be disabled +# 'handlers': ['console', 'file'], +# }, +# } +# } +# Default: {} +# c.Application.logging_config = {} + +## Instead of starting the Application, dump configuration to stdout +# Default: False +# c.Application.show_config = False + +## Instead of starting the Application, dump configuration to stdout (as JSON) +# Default: False +# c.Application.show_config_json = False + +#------------------------------------------------------------------------------ +# JupyterApp(Application) configuration +#------------------------------------------------------------------------------ +## Base class for Jupyter applications + +## Answer yes to any prompts. +# Default: False +# c.JupyterApp.answer_yes = False + +## Full path of a config file. +# Default: '' +# c.JupyterApp.config_file = '' + +## Specify a config file to load. +# Default: '' +# c.JupyterApp.config_file_name = '' + +## Generate default config file. +# Default: False +# c.JupyterApp.generate_config = False + +## The date format used by logging formatters for %(asctime)s +# See also: Application.log_datefmt +# c.JupyterApp.log_datefmt = '%Y-%m-%d %H:%M:%S' + +## The Logging format template +# See also: Application.log_format +# c.JupyterApp.log_format = '[%(name)s]%(highlevel)s %(message)s' + +## Set the log level by value or name. +# See also: Application.log_level +# c.JupyterApp.log_level = 30 + +## +# See also: Application.logging_config +# c.JupyterApp.logging_config = {} + +## Instead of starting the Application, dump configuration to stdout +# See also: Application.show_config +# c.JupyterApp.show_config = False + +## Instead of starting the Application, dump configuration to stdout (as JSON) +# See also: Application.show_config_json +# c.JupyterApp.show_config_json = False + +#------------------------------------------------------------------------------ +# ExtensionApp(JupyterApp) configuration +#------------------------------------------------------------------------------ +## Base class for configurable Jupyter Server Extension Applications. +# +# ExtensionApp subclasses can be initialized two ways: +# +# - Extension is listed as a jpserver_extension, and ServerApp calls +# its load_jupyter_server_extension classmethod. This is the +# classic way of loading a server extension. +# +# - Extension is launched directly by calling its `launch_instance` +# class method. This method can be set as a entry_point in +# the extensions setup.py. + +## Answer yes to any prompts. +# See also: JupyterApp.answer_yes +# c.ExtensionApp.answer_yes = False + +## Full path of a config file. +# See also: JupyterApp.config_file +# c.ExtensionApp.config_file = '' + +## Specify a config file to load. +# See also: JupyterApp.config_file_name +# c.ExtensionApp.config_file_name = '' + +# Default: '' +# c.ExtensionApp.default_url = '' + +## Generate default config file. +# See also: JupyterApp.generate_config +# c.ExtensionApp.generate_config = False + +## Handlers appended to the server. +# Default: [] +# c.ExtensionApp.handlers = [] + +## The date format used by logging formatters for %(asctime)s +# See also: Application.log_datefmt +# c.ExtensionApp.log_datefmt = '%Y-%m-%d %H:%M:%S' + +## The Logging format template +# See also: Application.log_format +# c.ExtensionApp.log_format = '[%(name)s]%(highlevel)s %(message)s' + +## Set the log level by value or name. +# See also: Application.log_level +# c.ExtensionApp.log_level = 30 + +## +# See also: Application.logging_config +# c.ExtensionApp.logging_config = {} + +## Whether to open in a browser after starting. +# The specific browser used is platform dependent and +# determined by the python standard library `webbrowser` +# module, unless it is overridden using the --browser +# (ServerApp.browser) configuration option. +# Default: False +# c.ExtensionApp.open_browser = False + +## Settings that will passed to the server. +# Default: {} +# c.ExtensionApp.settings = {} + +## Instead of starting the Application, dump configuration to stdout +# See also: Application.show_config +# c.ExtensionApp.show_config = False + +## Instead of starting the Application, dump configuration to stdout (as JSON) +# See also: Application.show_config_json +# c.ExtensionApp.show_config_json = False + +## paths to search for serving static files. +# +# This allows adding javascript/css to be available from the notebook server machine, +# or overriding individual files in the IPython +# Default: [] +# c.ExtensionApp.static_paths = [] + +## Url where the static assets for the extension are served. +# Default: '' +# c.ExtensionApp.static_url_prefix = '' + +## Paths to search for serving jinja templates. +# +# Can be used to override templates from notebook.templates. +# Default: [] +# c.ExtensionApp.template_paths = [] + +#------------------------------------------------------------------------------ +# LabServerApp(ExtensionApp) configuration +#------------------------------------------------------------------------------ +## A Lab Server Application that runs out-of-the-box + +## "A list of comma-separated URIs to get the allowed extensions list +# +# .. versionchanged:: 2.0.0 +# `LabServerApp.whitetlist_uris` renamed to `allowed_extensions_uris` +# Default: '' +# c.LabServerApp.allowed_extensions_uris = '' + +## Answer yes to any prompts. +# See also: JupyterApp.answer_yes +# c.LabServerApp.answer_yes = False + +## The application settings directory. +# Default: '' +# c.LabServerApp.app_settings_dir = '' + +## The url path for the application. +# Default: '/lab' +# c.LabServerApp.app_url = '/lab' + +## Deprecated, use `LabServerApp.blocked_extensions_uris` +# Default: '' +# c.LabServerApp.blacklist_uris = '' + +## A list of comma-separated URIs to get the blocked extensions list +# +# .. versionchanged:: 2.0.0 +# `LabServerApp.blacklist_uris` renamed to `blocked_extensions_uris` +# Default: '' +# c.LabServerApp.blocked_extensions_uris = '' + +## Whether to cache files on the server. This should be `True` except in dev +# mode. +# Default: True +# c.LabServerApp.cache_files = True + +## Full path of a config file. +# See also: JupyterApp.config_file +# c.LabServerApp.config_file = '' + +## Specify a config file to load. +# See also: JupyterApp.config_file_name +# c.LabServerApp.config_file_name = '' + +## Extra paths to look for federated JupyterLab extensions +# Default: [] +# c.LabServerApp.extra_labextensions_path = [] + +## Generate default config file. +# See also: JupyterApp.generate_config +# c.LabServerApp.generate_config = False + +## Handlers appended to the server. +# See also: ExtensionApp.handlers +# c.LabServerApp.handlers = [] + +## Options to pass to the jinja2 environment for this +# Default: {} +# c.LabServerApp.jinja2_options = {} + +## The standard paths to look in for federated JupyterLab extensions +# Default: [] +# c.LabServerApp.labextensions_path = [] + +## The url for federated JupyterLab extensions +# Default: '' +# c.LabServerApp.labextensions_url = '' + +## The interval delay in seconds to refresh the lists +# Default: 3600 +# c.LabServerApp.listings_refresh_seconds = 3600 + +## The optional kwargs to use for the listings HTTP requests as +# described on https://2.python-requests.org/en/v2.7.0/api/#requests.request +# Default: {} +# c.LabServerApp.listings_request_options = {} + +## The listings url. +# Default: '' +# c.LabServerApp.listings_url = '' + +## The date format used by logging formatters for %(asctime)s +# See also: Application.log_datefmt +# c.LabServerApp.log_datefmt = '%Y-%m-%d %H:%M:%S' + +## The Logging format template +# See also: Application.log_format +# c.LabServerApp.log_format = '[%(name)s]%(highlevel)s %(message)s' + +## Set the log level by value or name. +# See also: Application.log_level +# c.LabServerApp.log_level = 30 + +## +# See also: Application.logging_config +# c.LabServerApp.logging_config = {} + +## Whether a notebook should start a kernel automatically. +# Default: True +# c.LabServerApp.notebook_starts_kernel = True + +## Whether to open in a browser after starting. +# See also: ExtensionApp.open_browser +# c.LabServerApp.open_browser = False + +## The optional location of the settings schemas directory. If given, a handler +# will be added for settings. +# Default: '' +# c.LabServerApp.schemas_dir = '' + +## Settings that will passed to the server. +# See also: ExtensionApp.settings +# c.LabServerApp.settings = {} + +## The url path of the settings handler. +# Default: '' +# c.LabServerApp.settings_url = '' + +## Instead of starting the Application, dump configuration to stdout +# See also: Application.show_config +# c.LabServerApp.show_config = False + +## Instead of starting the Application, dump configuration to stdout (as JSON) +# See also: Application.show_config_json +# c.LabServerApp.show_config_json = False + +## The optional location of local static files. If given, a static file handler +# will be added. +# Default: '' +# c.LabServerApp.static_dir = '' + +## paths to search for serving static files. +# See also: ExtensionApp.static_paths +# c.LabServerApp.static_paths = [] + +## Url where the static assets for the extension are served. +# See also: ExtensionApp.static_url_prefix +# c.LabServerApp.static_url_prefix = '' + +## Paths to search for serving jinja templates. +# See also: ExtensionApp.template_paths +# c.LabServerApp.template_paths = [] + +## The application templates directory. +# Default: '' +# c.LabServerApp.templates_dir = '' + +## The optional location of the themes directory. If given, a handler will be +# added for themes. +# Default: '' +# c.LabServerApp.themes_dir = '' + +## The theme url. +# Default: '' +# c.LabServerApp.themes_url = '' + +## The url path of the translations handler. +# Default: '' +# c.LabServerApp.translations_api_url = '' + +## The url path of the tree handler. +# Default: '' +# c.LabServerApp.tree_url = '' + +## The optional location of the user settings directory. +# Default: '' +# c.LabServerApp.user_settings_dir = '' + +## Deprecated, use `LabServerApp.allowed_extensions_uris` +# Default: '' +# c.LabServerApp.whitelist_uris = '' + +## The url path of the workspaces API. +# Default: '' +# c.LabServerApp.workspaces_api_url = '' + +## The optional location of the saved workspaces directory. If given, a handler +# will be added for workspaces. +# Default: '' +# c.LabServerApp.workspaces_dir = '' + +#------------------------------------------------------------------------------ +# LabApp(LabServerApp) configuration +#------------------------------------------------------------------------------ +## +# See also: LabServerApp.allowed_extensions_uris +# c.LabApp.allowed_extensions_uris = '' + +## Answer yes to any prompts. +# See also: JupyterApp.answer_yes +# c.LabApp.answer_yes = False + +## The app directory to launch JupyterLab from. +# Default: None +# c.LabApp.app_dir = None + +## The application settings directory. +# Default: '' +# c.LabApp.app_settings_dir = '' + +## The url path for the application. +# Default: '/lab' +# c.LabApp.app_url = '/lab' + +## Deprecated, use `LabServerApp.blocked_extensions_uris` +# See also: LabServerApp.blacklist_uris +# c.LabApp.blacklist_uris = '' + +## +# See also: LabServerApp.blocked_extensions_uris +# c.LabApp.blocked_extensions_uris = '' + +## Whether to cache files on the server. This should be `True` except in dev +# mode. +# Default: True +# c.LabApp.cache_files = True + +## A callable class that receives the current version at instantiation and +# calling it must return asynchronously a string indicating which version is +# available and how to install or None if no update is available. The string +# supports Markdown format. +# Default: 'jupyterlab.handlers.announcements.CheckForUpdate' +# c.LabApp.check_for_updates_class = 'jupyterlab.handlers.announcements.CheckForUpdate' + +## Whether to enable collaborative mode. +# Default: False +# c.LabApp.collaborative = False + +## Full path of a config file. +# See also: JupyterApp.config_file +# c.LabApp.config_file = '' + +## Specify a config file to load. +# See also: JupyterApp.config_file_name +# c.LabApp.config_file_name = '' + +## Whether to start the app in core mode. In this mode, JupyterLab +# will run using the JavaScript assets that are within the installed +# JupyterLab Python package. In core mode, third party extensions are disabled. +# The `--dev-mode` flag is an alias to this to be used when the Python package +# itself is installed in development mode (`pip install -e .`). +# Default: False +# c.LabApp.core_mode = False + +## The default URL to redirect to from `/` +# Default: '/lab' +# c.LabApp.default_url = '/lab' + +## Whether to start the app in dev mode. Uses the unpublished local +# JavaScript packages in the `dev_mode` folder. In this case JupyterLab will +# show a red stripe at the top of the page. It can only be used if JupyterLab +# is installed as `pip install -e .`. +# Default: False +# c.LabApp.dev_mode = False + +## Whether to expose the global app instance to browser via window.jupyterlab +# Default: False +# c.LabApp.expose_app_in_browser = False + +## Whether to load prebuilt extensions in dev mode. This may be +# useful to run and test prebuilt extensions in development installs of +# JupyterLab. APIs in a JupyterLab development install may be +# incompatible with published packages, so prebuilt extensions compiled +# against published packages may not work correctly. +# Default: False +# c.LabApp.extensions_in_dev_mode = False + +## Extra paths to look for federated JupyterLab extensions +# Default: [] +# c.LabApp.extra_labextensions_path = [] + +## Whether to skip loading styles for disabled prebuilt extensions. +# This will be the default behavior starting with JupyterLab 4.0 +# (and this flag will be removed). +# Default: False +# c.LabApp.future_skip_styles_for_disabled = False + +## Generate default config file. +# See also: JupyterApp.generate_config +# c.LabApp.generate_config = False + +## Handlers appended to the server. +# See also: ExtensionApp.handlers +# c.LabApp.handlers = [] + +## Options to pass to the jinja2 environment for this +# Default: {} +# c.LabApp.jinja2_options = {} + +## The standard paths to look in for federated JupyterLab extensions +# Default: [] +# c.LabApp.labextensions_path = [] + +## The url for federated JupyterLab extensions +# Default: '' +# c.LabApp.labextensions_url = '' + +## The interval delay in seconds to refresh the lists +# See also: LabServerApp.listings_refresh_seconds +# c.LabApp.listings_refresh_seconds = 3600 + +## The optional kwargs to use for the listings HTTP requests as +# described on https://2.python-requests.org/en/v2.7.0/api/#requests.request +# See also: LabServerApp.listings_request_options +# c.LabApp.listings_request_options = {} + +## The listings url. +# Default: '' +# c.LabApp.listings_url = '' + +## The date format used by logging formatters for %(asctime)s +# See also: Application.log_datefmt +# c.LabApp.log_datefmt = '%Y-%m-%d %H:%M:%S' + +## The Logging format template +# See also: Application.log_format +# c.LabApp.log_format = '[%(name)s]%(highlevel)s %(message)s' + +## Set the log level by value or name. +# See also: Application.log_level +# c.LabApp.log_level = 30 + +## +# See also: Application.logging_config +# c.LabApp.logging_config = {} + +## URL that serves news Atom feed; by default the JupyterLab organization +# announcements will be fetched. Set to None to turn off fetching announcements. +# Default: 'https://jupyterlab.github.io/assets/feed.xml' +# c.LabApp.news_url = 'https://jupyterlab.github.io/assets/feed.xml' + +## Whether a notebook should start a kernel automatically. +# Default: True +# c.LabApp.notebook_starts_kernel = True + +## Whether to open in a browser after starting. +# See also: ExtensionApp.open_browser +# c.LabApp.open_browser = False + +## The override url for static lab assets, typically a CDN. +# Default: '' +# c.LabApp.override_static_url = '' + +## The override url for static lab theme assets, typically a CDN. +# Default: '' +# c.LabApp.override_theme_url = '' + +## The optional location of the settings schemas directory. If given, a handler +# will be added for settings. +# Default: '' +# c.LabApp.schemas_dir = '' + +## Settings that will passed to the server. +# See also: ExtensionApp.settings +# c.LabApp.settings = {} + +## The url path of the settings handler. +# Default: '' +# c.LabApp.settings_url = '' + +## Instead of starting the Application, dump configuration to stdout +# See also: Application.show_config +# c.LabApp.show_config = False + +## Instead of starting the Application, dump configuration to stdout (as JSON) +# See also: Application.show_config_json +# c.LabApp.show_config_json = False + +## Splice source packages into app directory. +# Default: False +# c.LabApp.splice_source = False + +## The optional location of local static files. If given, a static file handler +# will be added. +# Default: '' +# c.LabApp.static_dir = '' + +## paths to search for serving static files. +# See also: ExtensionApp.static_paths +# c.LabApp.static_paths = [] + +## Url where the static assets for the extension are served. +# See also: ExtensionApp.static_url_prefix +# c.LabApp.static_url_prefix = '' + +## Paths to search for serving jinja templates. +# See also: ExtensionApp.template_paths +# c.LabApp.template_paths = [] + +## The application templates directory. +# Default: '' +# c.LabApp.templates_dir = '' + +## The optional location of the themes directory. If given, a handler will be +# added for themes. +# Default: '' +# c.LabApp.themes_dir = '' + +## The theme url. +# Default: '' +# c.LabApp.themes_url = '' + +## The url path of the translations handler. +# Default: '' +# c.LabApp.translations_api_url = '' + +## The url path of the tree handler. +# Default: '' +# c.LabApp.tree_url = '' + +## The directory for user settings. +# Default: '/Users/lsetiawan/.jupyter/lab/user-settings' +# c.LabApp.user_settings_dir = '/Users/lsetiawan/.jupyter/lab/user-settings' + +## Whether to serve the app in watch mode +# Default: False +# c.LabApp.watch = False + +## Deprecated, use `LabServerApp.allowed_extensions_uris` +# See also: LabServerApp.whitelist_uris +# c.LabApp.whitelist_uris = '' + +## The url path of the workspaces API. +# Default: '' +# c.LabApp.workspaces_api_url = '' + +## The directory for workspaces +# Default: '/Users/lsetiawan/.jupyter/lab/workspaces' +# c.LabApp.workspaces_dir = '/Users/lsetiawan/.jupyter/lab/workspaces' + +#------------------------------------------------------------------------------ +# ServerApp(JupyterApp) configuration +#------------------------------------------------------------------------------ +## The Jupyter Server application class. + +## Set the Access-Control-Allow-Credentials: true header +# Default: False +# c.ServerApp.allow_credentials = False + +## Set the Access-Control-Allow-Origin header +# +# Use '*' to allow any origin to access your server. +# +# Takes precedence over allow_origin_pat. +# Default: '' +# c.ServerApp.allow_origin = '' + +## Use a regular expression for the Access-Control-Allow-Origin header +# +# Requests from an origin matching the expression will get replies with: +# +# Access-Control-Allow-Origin: origin +# +# where `origin` is the origin of the request. +# +# Ignored if allow_origin is set. +# Default: '' +# c.ServerApp.allow_origin_pat = '' + +## DEPRECATED in 2.0. Use PasswordIdentityProvider.allow_password_change +# Default: True +# c.ServerApp.allow_password_change = True + +## Allow requests where the Host header doesn't point to a local server +# +# By default, requests get a 403 forbidden response if the 'Host' header +# shows that the browser thinks it's on a non-local domain. +# Setting this option to True disables this check. +# +# This protects against 'DNS rebinding' attacks, where a remote web server +# serves you a page and then changes its DNS to send later requests to a +# local IP, bypassing same-origin checks. +# +# Local IP addresses (such as 127.0.0.1 and ::1) are allowed as local, +# along with hostnames configured in local_hostnames. +# Default: False +# c.ServerApp.allow_remote_access = False + +## Whether to allow the user to run the server as root. +# Default: False +# c.ServerApp.allow_root = False + +## Answer yes to any prompts. +# See also: JupyterApp.answer_yes +# c.ServerApp.answer_yes = False + +## " +# Require authentication to access prometheus metrics. +# Default: True +# c.ServerApp.authenticate_prometheus = True + +## The authorizer class to use. +# Default: 'jupyter_server.auth.authorizer.AllowAllAuthorizer' +# c.ServerApp.authorizer_class = 'jupyter_server.auth.authorizer.AllowAllAuthorizer' + +## Reload the webapp when changes are made to any Python src files. +# Default: False +# c.ServerApp.autoreload = False + +## The base URL for the Jupyter server. +# +# Leading and trailing slashes can be omitted, +# and will automatically be added. +# Default: '/' +# c.ServerApp.base_url = '/' + +## Specify what command to use to invoke a web +# browser when starting the server. If not specified, the +# default browser will be determined by the `webbrowser` +# standard library module, which allows setting of the +# BROWSER environment variable to override it. +# Default: '' +# c.ServerApp.browser = '' + +## The full path to an SSL/TLS certificate file. +# Default: '' +# c.ServerApp.certfile = '' + +## The full path to a certificate authority certificate for SSL/TLS client +# authentication. +# Default: '' +# c.ServerApp.client_ca = '' + +## Full path of a config file. +# See also: JupyterApp.config_file +# c.ServerApp.config_file = '' + +## Specify a config file to load. +# See also: JupyterApp.config_file_name +# c.ServerApp.config_file_name = '' + +## The config manager class to use +# Default: 'jupyter_server.services.config.manager.ConfigManager' +# c.ServerApp.config_manager_class = 'jupyter_server.services.config.manager.ConfigManager' + +## The content manager class to use. +# Default: 'jupyter_server.services.contents.largefilemanager.AsyncLargeFileManager' +# c.ServerApp.contents_manager_class = 'jupyter_server.services.contents.largefilemanager.AsyncLargeFileManager' + +## DEPRECATED. Use IdentityProvider.cookie_options +# Default: {} +# c.ServerApp.cookie_options = {} + +## The random bytes used to secure cookies. +# By default this is a new random number every time you start the server. +# Set it to a value in a config file to enable logins to persist across server sessions. +# +# Note: Cookie secrets should be kept private, do not share config files with +# cookie_secret stored in plaintext (you can read the value from a file). +# Default: b'' +# c.ServerApp.cookie_secret = b'' + +## The file where the cookie secret is stored. +# Default: '' +# c.ServerApp.cookie_secret_file = '' + +## Override URL shown to users. +# +# Replace actual URL, including protocol, address, port and base URL, +# with the given value when displaying URL to the users. Do not change +# the actual connection URL. If authentication token is enabled, the +# token is added to the custom URL automatically. +# +# This option is intended to be used when the URL to display to the user +# cannot be determined reliably by the Jupyter server (proxified +# or containerized setups for example). +# Default: '' +# c.ServerApp.custom_display_url = '' + +## The default URL to redirect to from `/` +# Default: '/' +# c.ServerApp.default_url = '/' + +## Disable cross-site-request-forgery protection +# +# Jupyter server includes protection from cross-site request forgeries, +# requiring API requests to either: +# +# - originate from pages served by this server (validated with XSRF cookie and token), or +# - authenticate with a token +# +# Some anonymous compute resources still desire the ability to run code, +# completely without authentication. +# These services can disable all authentication and security checks, +# with the full knowledge of what that implies. +# Default: False +# c.ServerApp.disable_check_xsrf = False + +## handlers that should be loaded at higher priority than the default services +# Default: [] +# c.ServerApp.extra_services = [] + +## Extra paths to search for serving static files. +# +# This allows adding javascript/css to be available from the Jupyter server machine, +# or overriding individual files in the IPython +# Default: [] +# c.ServerApp.extra_static_paths = [] + +## Extra paths to search for serving jinja templates. +# +# Can be used to override templates from jupyter_server.templates. +# Default: [] +# c.ServerApp.extra_template_paths = [] + +## Open the named file when the application is launched. +# Default: '' +# c.ServerApp.file_to_run = '' + +## The URL prefix where files are opened directly. +# Default: 'notebooks' +# c.ServerApp.file_url_prefix = 'notebooks' + +## Generate default config file. +# See also: JupyterApp.generate_config +# c.ServerApp.generate_config = False + +## DEPRECATED. Use IdentityProvider.get_secure_cookie_kwargs +# Default: {} +# c.ServerApp.get_secure_cookie_kwargs = {} + +## The identity provider class to use. +# Default: 'jupyter_server.auth.identity.PasswordIdentityProvider' +# c.ServerApp.identity_provider_class = 'jupyter_server.auth.identity.PasswordIdentityProvider' + +## DEPRECATED. Use ZMQChannelsWebsocketConnection.iopub_data_rate_limit +# Default: 0.0 +# c.ServerApp.iopub_data_rate_limit = 0.0 + +## DEPRECATED. Use ZMQChannelsWebsocketConnection.iopub_msg_rate_limit +# Default: 0.0 +# c.ServerApp.iopub_msg_rate_limit = 0.0 + +## The IP address the Jupyter server will listen on. +# Default: 'localhost' +# c.ServerApp.ip = 'localhost' + +## Supply extra arguments that will be passed to Jinja environment. +# Default: {} +# c.ServerApp.jinja_environment_options = {} + +## Extra variables to supply to jinja templates when rendering. +# Default: {} +# c.ServerApp.jinja_template_vars = {} + +## Dict of Python modules to load as Jupyter server extensions.Entry values can +# be used to enable and disable the loading ofthe extensions. The extensions +# will be loaded in alphabetical order. +# Default: {} +# c.ServerApp.jpserver_extensions = {} + +## The kernel manager class to use. +# Default: 'jupyter_server.services.kernels.kernelmanager.MappingKernelManager' +# c.ServerApp.kernel_manager_class = 'jupyter_server.services.kernels.kernelmanager.MappingKernelManager' + +## The kernel spec manager class to use. Should be a subclass of +# `jupyter_client.kernelspec.KernelSpecManager`. +# +# The Api of KernelSpecManager is provisional and might change without warning +# between this version of Jupyter and the next stable one. +# Default: 'builtins.object' +# c.ServerApp.kernel_spec_manager_class = 'builtins.object' + +## The kernel websocket connection class to use. +# Default: 'jupyter_server.services.kernels.connection.channels.ZMQChannelsWebsocketConnection' +# c.ServerApp.kernel_websocket_connection_class = 'jupyter_server.services.kernels.connection.channels.ZMQChannelsWebsocketConnection' + +## DEPRECATED. Use ZMQChannelsWebsocketConnection.kernel_ws_protocol +# Default: '' +# c.ServerApp.kernel_ws_protocol = '' + +## The full path to a private key file for usage with SSL/TLS. +# Default: '' +# c.ServerApp.keyfile = '' + +## DEPRECATED. Use ZMQChannelsWebsocketConnection.limit_rate +# Default: False +# c.ServerApp.limit_rate = False + +## Hostnames to allow as local when allow_remote_access is False. +# +# Local IP addresses (such as 127.0.0.1 and ::1) are automatically accepted +# as local as well. +# Default: ['localhost'] +# c.ServerApp.local_hostnames = ['localhost'] + +## The date format used by logging formatters for %(asctime)s +# See also: Application.log_datefmt +# c.ServerApp.log_datefmt = '%Y-%m-%d %H:%M:%S' + +## The Logging format template +# See also: Application.log_format +# c.ServerApp.log_format = '[%(name)s]%(highlevel)s %(message)s' + +## Set the log level by value or name. +# See also: Application.log_level +# c.ServerApp.log_level = 30 + +## +# See also: Application.logging_config +# c.ServerApp.logging_config = {} + +## The login handler class to use. +# Default: 'jupyter_server.auth.login.LegacyLoginHandler' +# c.ServerApp.login_handler_class = 'jupyter_server.auth.login.LegacyLoginHandler' + +## The logout handler class to use. +# Default: 'jupyter_server.auth.logout.LogoutHandler' +# c.ServerApp.logout_handler_class = 'jupyter_server.auth.logout.LogoutHandler' + +## Sets the maximum allowed size of the client request body, specified in the +# Content-Length request header field. If the size in a request exceeds the +# configured value, a malformed HTTP message is returned to the client. +# +# Note: max_body_size is applied even in streaming mode. +# Default: 536870912 +# c.ServerApp.max_body_size = 536870912 + +## Gets or sets the maximum amount of memory, in bytes, that is allocated for use +# by the buffer manager. +# Default: 536870912 +# c.ServerApp.max_buffer_size = 536870912 + +## Gets or sets a lower bound on the open file handles process resource limit. +# This may need to be increased if you run into an OSError: [Errno 24] Too many +# open files. This is not applicable when running on Windows. +# Default: 0 +# c.ServerApp.min_open_files_limit = 0 + +## DEPRECATED, use root_dir. +# Default: '' +# c.ServerApp.notebook_dir = '' + +## Whether to open in a browser after starting. +# The specific browser used is platform dependent and +# determined by the python standard library `webbrowser` +# module, unless it is overridden using the --browser +# (ServerApp.browser) configuration option. +# Default: False +# c.ServerApp.open_browser = False + +## DEPRECATED in 2.0. Use PasswordIdentityProvider.hashed_password +# Default: '' +# c.ServerApp.password = '' + +## DEPRECATED in 2.0. Use PasswordIdentityProvider.password_required +# Default: False +# c.ServerApp.password_required = False + +## The port the server will listen on (env: JUPYTER_PORT). +# Default: 0 +# c.ServerApp.port = 0 + +## The number of additional ports to try if the specified port is not available +# (env: JUPYTER_PORT_RETRIES). +# Default: 50 +# c.ServerApp.port_retries = 50 + +## Preferred starting directory to use for notebooks and kernels. +# Default: '' +# c.ServerApp.preferred_dir = '' + +## DISABLED: use %pylab or %matplotlib in the notebook to enable matplotlib. +# Default: 'disabled' +# c.ServerApp.pylab = 'disabled' + +## If True, display controls to shut down the Jupyter server, such as menu items +# or buttons. +# Default: True +# c.ServerApp.quit_button = True + +## DEPRECATED. Use ZMQChannelsWebsocketConnection.rate_limit_window +# Default: 0.0 +# c.ServerApp.rate_limit_window = 0.0 + +## Reraise exceptions encountered loading server extensions? +# Default: False +# c.ServerApp.reraise_server_extension_failures = False + +## The directory to use for notebooks and kernels. +# Default: '' +# c.ServerApp.root_dir = '' + +## The session manager class to use. +# Default: 'builtins.object' +# c.ServerApp.session_manager_class = 'builtins.object' + +## Instead of starting the Application, dump configuration to stdout +# See also: Application.show_config +# c.ServerApp.show_config = False + +## Instead of starting the Application, dump configuration to stdout (as JSON) +# See also: Application.show_config_json +# c.ServerApp.show_config_json = False + +## Shut down the server after N seconds with no kernelsrunning and no activity. +# This can be used together with culling idle kernels +# (MappingKernelManager.cull_idle_timeout) to shutdown the Jupyter server when +# it's not in use. This is not precisely timed: it may shut down up to a minute +# later. 0 (the default) disables this automatic shutdown. +# Default: 0 +# c.ServerApp.shutdown_no_activity_timeout = 0 + +## The UNIX socket the Jupyter server will listen on. +# Default: '' +# c.ServerApp.sock = '' + +## The permissions mode for UNIX socket creation (default: 0600). +# Default: '0600' +# c.ServerApp.sock_mode = '0600' + +## Supply SSL options for the tornado HTTPServer. +# See the tornado docs for details. +# Default: {} +# c.ServerApp.ssl_options = {} + +## Supply overrides for terminado. Currently only supports "shell_command". +# Default: {} +# c.ServerApp.terminado_settings = {} + +## Set to False to disable terminals. +# +# This does *not* make the server more secure by itself. +# Anything the user can in a terminal, they can also do in a notebook. +# +# Terminals may also be automatically disabled if the terminado package +# is not available. +# Default: False +# c.ServerApp.terminals_enabled = False + +## DEPRECATED. Use IdentityProvider.token +# Default: '' +# c.ServerApp.token = '' + +## Supply overrides for the tornado.web.Application that the Jupyter server uses. +# Default: {} +# c.ServerApp.tornado_settings = {} + +## Whether to trust or not X-Scheme/X-Forwarded-Proto and X-Real-Ip/X-Forwarded- +# For headerssent by the upstream reverse proxy. Necessary if the proxy handles +# SSL +# Default: False +# c.ServerApp.trust_xheaders = False + +## Disable launching browser by redirect file +# For versions of notebook > 5.7.2, a security feature measure was added that +# prevented the authentication token used to launch the browser from being visible. +# This feature makes it difficult for other users on a multi-user system from +# running code in your Jupyter session as you. +# However, some environments (like Windows Subsystem for Linux (WSL) and Chromebooks), +# launching a browser using a redirect file can lead the browser failing to load. +# This is because of the difference in file structures/paths between the runtime and +# the browser. +# +# Disabling this setting to False will disable this behavior, allowing the browser +# to launch by using a URL and visible token (as before). +# Default: True +# c.ServerApp.use_redirect_file = True + +## Specify where to open the server on startup. This is the +# `new` argument passed to the standard library method `webbrowser.open`. +# The behaviour is not guaranteed, but depends on browser support. Valid +# values are: +# +# - 2 opens a new tab, +# - 1 opens a new window, +# - 0 opens in an existing window. +# +# See the `webbrowser.open` documentation for details. +# Default: 2 +# c.ServerApp.webbrowser_open_new = 2 + +## Set the tornado compression options for websocket connections. +# +# This value will be returned from +# :meth:`WebSocketHandler.get_compression_options`. None (default) will disable +# compression. A dict (even an empty one) will enable compression. +# +# See the tornado docs for WebSocketHandler.get_compression_options for details. +# Default: None +# c.ServerApp.websocket_compression_options = None + +## The base URL for websockets, +# if it differs from the HTTP server (hint: it almost certainly doesn't). +# +# Should be in the form of an HTTP origin: ws[s]://hostname[:port] +# Default: '' +# c.ServerApp.websocket_url = '' From c24b4d38ac822037096d4c814c70355f1398849d Mon Sep 17 00:00:00 2001 From: Landung 'Don' Setiawan Date: Thu, 22 Jun 2023 16:08:02 -0700 Subject: [PATCH 14/36] Moving out of binder folder in conda --- conda/{binder => }/apt.txt | 0 conda/{binder => }/jupyter_lab_config.py | 0 2 files changed, 0 insertions(+), 0 deletions(-) rename conda/{binder => }/apt.txt (100%) rename conda/{binder => }/jupyter_lab_config.py (100%) diff --git a/conda/binder/apt.txt b/conda/apt.txt similarity index 100% rename from conda/binder/apt.txt rename to conda/apt.txt diff --git a/conda/binder/jupyter_lab_config.py b/conda/jupyter_lab_config.py similarity index 100% rename from conda/binder/jupyter_lab_config.py rename to conda/jupyter_lab_config.py From d486c793f422722cf16d9f7ca45b7eff41cc2dd3 Mon Sep 17 00:00:00 2001 From: Landung 'Don' Setiawan Date: Thu, 22 Jun 2023 16:42:48 -0700 Subject: [PATCH 15/36] Move config and try postCreateCommand --- .devcontainer/scipy2023/devcontainer.json | 3 +++ {conda => .devcontainer/scipy2023}/jupyter_lab_config.py | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) rename {conda => .devcontainer/scipy2023}/jupyter_lab_config.py (99%) diff --git a/.devcontainer/scipy2023/devcontainer.json b/.devcontainer/scipy2023/devcontainer.json index 798d8418..990a7a40 100644 --- a/.devcontainer/scipy2023/devcontainer.json +++ b/.devcontainer/scipy2023/devcontainer.json @@ -3,6 +3,9 @@ "dockerfile": "../Dockerfile", "context": "../../conda" }, + "postCreateCommand": { + "juperlab": "cp .devcontainer/scipy2023/jupyter_lab_config.py /home/jovyan/.jupyter/jupyter_lab_config.py && jupyter lab" + }, "hostRequirements": { "cpus": 2 }, diff --git a/conda/jupyter_lab_config.py b/.devcontainer/scipy2023/jupyter_lab_config.py similarity index 99% rename from conda/jupyter_lab_config.py rename to .devcontainer/scipy2023/jupyter_lab_config.py index 0494bb61..a9c8e20e 100644 --- a/conda/jupyter_lab_config.py +++ b/.devcontainer/scipy2023/jupyter_lab_config.py @@ -461,7 +461,7 @@ ## The default URL to redirect to from `/` # Default: '/lab' -# c.LabApp.default_url = '/lab' +c.LabApp.default_url = '/lab/tree/workshops/scipy2023/index.ipynb' ## Whether to start the app in dev mode. Uses the unpublished local # JavaScript packages in the `dev_mode` folder. In this case JupyterLab will From 02e53b8d7511c1f42761bcc8193951a93a5efddb Mon Sep 17 00:00:00 2001 From: Landung 'Don' Setiawan Date: Thu, 22 Jun 2023 16:52:48 -0700 Subject: [PATCH 16/36] Add create .jupyter folder --- .devcontainer/scipy2023/devcontainer.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.devcontainer/scipy2023/devcontainer.json b/.devcontainer/scipy2023/devcontainer.json index 990a7a40..aca95bf4 100644 --- a/.devcontainer/scipy2023/devcontainer.json +++ b/.devcontainer/scipy2023/devcontainer.json @@ -3,8 +3,8 @@ "dockerfile": "../Dockerfile", "context": "../../conda" }, - "postCreateCommand": { - "juperlab": "cp .devcontainer/scipy2023/jupyter_lab_config.py /home/jovyan/.jupyter/jupyter_lab_config.py && jupyter lab" + "postStartCommand": { + "juperlab": "mkdir /home/jovyan/.jupyter && cp .devcontainer/scipy2023/jupyter_lab_config.py /home/jovyan/.jupyter/jupyter_lab_config.py && jupyter lab" }, "hostRequirements": { "cpus": 2 From abee1390e71e4f4e9170356cf7052ab657bb61da Mon Sep 17 00:00:00 2001 From: Landung 'Don' Setiawan Date: Thu, 22 Jun 2023 17:02:17 -0700 Subject: [PATCH 17/36] Change to post create and copy lab config only --- .devcontainer/scipy2023/devcontainer.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.devcontainer/scipy2023/devcontainer.json b/.devcontainer/scipy2023/devcontainer.json index aca95bf4..ed47b620 100644 --- a/.devcontainer/scipy2023/devcontainer.json +++ b/.devcontainer/scipy2023/devcontainer.json @@ -3,8 +3,8 @@ "dockerfile": "../Dockerfile", "context": "../../conda" }, - "postStartCommand": { - "juperlab": "mkdir /home/jovyan/.jupyter && cp .devcontainer/scipy2023/jupyter_lab_config.py /home/jovyan/.jupyter/jupyter_lab_config.py && jupyter lab" + "postCreateCommand": { + "juperlab": "mkdir /home/jovyan/.jupyter && cp .devcontainer/scipy2023/jupyter_lab_config.py /home/jovyan/.jupyter/jupyter_lab_config.py" }, "hostRequirements": { "cpus": 2 From 44d6656dc3700df941d6541c1c003958549a41c3 Mon Sep 17 00:00:00 2001 From: Landung 'Don' Setiawan Date: Thu, 22 Jun 2023 17:23:02 -0700 Subject: [PATCH 18/36] Add small readme --- workshops/scipy2023/README.md | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/workshops/scipy2023/README.md b/workshops/scipy2023/README.md index 47bd449f..cfc17f94 100644 --- a/workshops/scipy2023/README.md +++ b/workshops/scipy2023/README.md @@ -19,6 +19,16 @@ See instructions to set up the environment for running the tutorial material [he For the live tutorial, we will be using the SciPy 2023 Nebari JupyterHub. Instructions for the live tutorial will be added soon. +## Github Codespaces + +This tutorial is available to run within github codespaces with the conda environment specification +in the [`conda-lock.yml`](../../conda/conda-lock.yml) file. + +[![Open in GitHub Codespaces](https://github.com/codespaces/badge.svg)](https://github.com/codespaces/new/xarray-contrib/xarray-tutorial/tree/main?devcontainer_path=.devcontainer%2Fscipy2023%2Fdevcontainer.json) + +Click the button above to launch the github codespaces. Once it's launched, a terminal will open. To use the Jupyter lab interface, simply run the command `jupyter lab` within the terminal to get the url, +at which point, you can click and open up the Jupyter lab interface. + ## Outline **🏗️ Outline coming soon! Please check back later** From 98e59b74a0b2680ced1cee55aaa75f39c9af2b92 Mon Sep 17 00:00:00 2001 From: Landung 'Don' Setiawan Date: Thu, 22 Jun 2023 17:26:42 -0700 Subject: [PATCH 19/36] Remove unecessary jupyter lab config --- .devcontainer/scipy2023/jupyter_lab_config.py | 1097 ----------------- 1 file changed, 1097 deletions(-) diff --git a/.devcontainer/scipy2023/jupyter_lab_config.py b/.devcontainer/scipy2023/jupyter_lab_config.py index a9c8e20e..2d744134 100644 --- a/.devcontainer/scipy2023/jupyter_lab_config.py +++ b/.devcontainer/scipy2023/jupyter_lab_config.py @@ -2,1104 +2,7 @@ c = get_config() #noqa -#------------------------------------------------------------------------------ -# Application(SingletonConfigurable) configuration -#------------------------------------------------------------------------------ -## This is an application. - -## The date format used by logging formatters for %(asctime)s -# Default: '%Y-%m-%d %H:%M:%S' -# c.Application.log_datefmt = '%Y-%m-%d %H:%M:%S' - -## The Logging format template -# Default: '[%(name)s]%(highlevel)s %(message)s' -# c.Application.log_format = '[%(name)s]%(highlevel)s %(message)s' - -## Set the log level by value or name. -# Choices: any of [0, 10, 20, 30, 40, 50, 'DEBUG', 'INFO', 'WARN', 'ERROR', 'CRITICAL'] -# Default: 30 -# c.Application.log_level = 30 - -## Configure additional log handlers. -# -# The default stderr logs handler is configured by the log_level, log_datefmt -# and log_format settings. -# -# This configuration can be used to configure additional handlers (e.g. to -# output the log to a file) or for finer control over the default handlers. -# -# If provided this should be a logging configuration dictionary, for more -# information see: -# https://docs.python.org/3/library/logging.config.html#logging-config- -# dictschema -# -# This dictionary is merged with the base logging configuration which defines -# the following: -# -# * A logging formatter intended for interactive use called -# ``console``. -# * A logging handler that writes to stderr called -# ``console`` which uses the formatter ``console``. -# * A logger with the name of this application set to ``DEBUG`` -# level. -# -# This example adds a new handler that writes to a file: -# -# .. code-block:: python -# -# c.Application.logging_config = { -# 'handlers': { -# 'file': { -# 'class': 'logging.FileHandler', -# 'level': 'DEBUG', -# 'filename': '', -# } -# }, -# 'loggers': { -# '': { -# 'level': 'DEBUG', -# # NOTE: if you don't list the default "console" -# # handler here then it will be disabled -# 'handlers': ['console', 'file'], -# }, -# } -# } -# Default: {} -# c.Application.logging_config = {} - -## Instead of starting the Application, dump configuration to stdout -# Default: False -# c.Application.show_config = False - -## Instead of starting the Application, dump configuration to stdout (as JSON) -# Default: False -# c.Application.show_config_json = False - -#------------------------------------------------------------------------------ -# JupyterApp(Application) configuration -#------------------------------------------------------------------------------ -## Base class for Jupyter applications - -## Answer yes to any prompts. -# Default: False -# c.JupyterApp.answer_yes = False - -## Full path of a config file. -# Default: '' -# c.JupyterApp.config_file = '' - -## Specify a config file to load. -# Default: '' -# c.JupyterApp.config_file_name = '' - -## Generate default config file. -# Default: False -# c.JupyterApp.generate_config = False - -## The date format used by logging formatters for %(asctime)s -# See also: Application.log_datefmt -# c.JupyterApp.log_datefmt = '%Y-%m-%d %H:%M:%S' - -## The Logging format template -# See also: Application.log_format -# c.JupyterApp.log_format = '[%(name)s]%(highlevel)s %(message)s' - -## Set the log level by value or name. -# See also: Application.log_level -# c.JupyterApp.log_level = 30 - -## -# See also: Application.logging_config -# c.JupyterApp.logging_config = {} - -## Instead of starting the Application, dump configuration to stdout -# See also: Application.show_config -# c.JupyterApp.show_config = False - -## Instead of starting the Application, dump configuration to stdout (as JSON) -# See also: Application.show_config_json -# c.JupyterApp.show_config_json = False - -#------------------------------------------------------------------------------ -# ExtensionApp(JupyterApp) configuration -#------------------------------------------------------------------------------ -## Base class for configurable Jupyter Server Extension Applications. -# -# ExtensionApp subclasses can be initialized two ways: -# -# - Extension is listed as a jpserver_extension, and ServerApp calls -# its load_jupyter_server_extension classmethod. This is the -# classic way of loading a server extension. -# -# - Extension is launched directly by calling its `launch_instance` -# class method. This method can be set as a entry_point in -# the extensions setup.py. - -## Answer yes to any prompts. -# See also: JupyterApp.answer_yes -# c.ExtensionApp.answer_yes = False - -## Full path of a config file. -# See also: JupyterApp.config_file -# c.ExtensionApp.config_file = '' - -## Specify a config file to load. -# See also: JupyterApp.config_file_name -# c.ExtensionApp.config_file_name = '' - -# Default: '' -# c.ExtensionApp.default_url = '' - -## Generate default config file. -# See also: JupyterApp.generate_config -# c.ExtensionApp.generate_config = False - -## Handlers appended to the server. -# Default: [] -# c.ExtensionApp.handlers = [] - -## The date format used by logging formatters for %(asctime)s -# See also: Application.log_datefmt -# c.ExtensionApp.log_datefmt = '%Y-%m-%d %H:%M:%S' - -## The Logging format template -# See also: Application.log_format -# c.ExtensionApp.log_format = '[%(name)s]%(highlevel)s %(message)s' - -## Set the log level by value or name. -# See also: Application.log_level -# c.ExtensionApp.log_level = 30 - -## -# See also: Application.logging_config -# c.ExtensionApp.logging_config = {} - -## Whether to open in a browser after starting. -# The specific browser used is platform dependent and -# determined by the python standard library `webbrowser` -# module, unless it is overridden using the --browser -# (ServerApp.browser) configuration option. -# Default: False -# c.ExtensionApp.open_browser = False - -## Settings that will passed to the server. -# Default: {} -# c.ExtensionApp.settings = {} - -## Instead of starting the Application, dump configuration to stdout -# See also: Application.show_config -# c.ExtensionApp.show_config = False - -## Instead of starting the Application, dump configuration to stdout (as JSON) -# See also: Application.show_config_json -# c.ExtensionApp.show_config_json = False - -## paths to search for serving static files. -# -# This allows adding javascript/css to be available from the notebook server machine, -# or overriding individual files in the IPython -# Default: [] -# c.ExtensionApp.static_paths = [] - -## Url where the static assets for the extension are served. -# Default: '' -# c.ExtensionApp.static_url_prefix = '' - -## Paths to search for serving jinja templates. -# -# Can be used to override templates from notebook.templates. -# Default: [] -# c.ExtensionApp.template_paths = [] - -#------------------------------------------------------------------------------ -# LabServerApp(ExtensionApp) configuration -#------------------------------------------------------------------------------ -## A Lab Server Application that runs out-of-the-box - -## "A list of comma-separated URIs to get the allowed extensions list -# -# .. versionchanged:: 2.0.0 -# `LabServerApp.whitetlist_uris` renamed to `allowed_extensions_uris` -# Default: '' -# c.LabServerApp.allowed_extensions_uris = '' - -## Answer yes to any prompts. -# See also: JupyterApp.answer_yes -# c.LabServerApp.answer_yes = False - -## The application settings directory. -# Default: '' -# c.LabServerApp.app_settings_dir = '' - -## The url path for the application. -# Default: '/lab' -# c.LabServerApp.app_url = '/lab' - -## Deprecated, use `LabServerApp.blocked_extensions_uris` -# Default: '' -# c.LabServerApp.blacklist_uris = '' - -## A list of comma-separated URIs to get the blocked extensions list -# -# .. versionchanged:: 2.0.0 -# `LabServerApp.blacklist_uris` renamed to `blocked_extensions_uris` -# Default: '' -# c.LabServerApp.blocked_extensions_uris = '' - -## Whether to cache files on the server. This should be `True` except in dev -# mode. -# Default: True -# c.LabServerApp.cache_files = True - -## Full path of a config file. -# See also: JupyterApp.config_file -# c.LabServerApp.config_file = '' - -## Specify a config file to load. -# See also: JupyterApp.config_file_name -# c.LabServerApp.config_file_name = '' - -## Extra paths to look for federated JupyterLab extensions -# Default: [] -# c.LabServerApp.extra_labextensions_path = [] - -## Generate default config file. -# See also: JupyterApp.generate_config -# c.LabServerApp.generate_config = False - -## Handlers appended to the server. -# See also: ExtensionApp.handlers -# c.LabServerApp.handlers = [] - -## Options to pass to the jinja2 environment for this -# Default: {} -# c.LabServerApp.jinja2_options = {} - -## The standard paths to look in for federated JupyterLab extensions -# Default: [] -# c.LabServerApp.labextensions_path = [] - -## The url for federated JupyterLab extensions -# Default: '' -# c.LabServerApp.labextensions_url = '' - -## The interval delay in seconds to refresh the lists -# Default: 3600 -# c.LabServerApp.listings_refresh_seconds = 3600 - -## The optional kwargs to use for the listings HTTP requests as -# described on https://2.python-requests.org/en/v2.7.0/api/#requests.request -# Default: {} -# c.LabServerApp.listings_request_options = {} - -## The listings url. -# Default: '' -# c.LabServerApp.listings_url = '' - -## The date format used by logging formatters for %(asctime)s -# See also: Application.log_datefmt -# c.LabServerApp.log_datefmt = '%Y-%m-%d %H:%M:%S' - -## The Logging format template -# See also: Application.log_format -# c.LabServerApp.log_format = '[%(name)s]%(highlevel)s %(message)s' - -## Set the log level by value or name. -# See also: Application.log_level -# c.LabServerApp.log_level = 30 - -## -# See also: Application.logging_config -# c.LabServerApp.logging_config = {} - -## Whether a notebook should start a kernel automatically. -# Default: True -# c.LabServerApp.notebook_starts_kernel = True - -## Whether to open in a browser after starting. -# See also: ExtensionApp.open_browser -# c.LabServerApp.open_browser = False - -## The optional location of the settings schemas directory. If given, a handler -# will be added for settings. -# Default: '' -# c.LabServerApp.schemas_dir = '' - -## Settings that will passed to the server. -# See also: ExtensionApp.settings -# c.LabServerApp.settings = {} - -## The url path of the settings handler. -# Default: '' -# c.LabServerApp.settings_url = '' - -## Instead of starting the Application, dump configuration to stdout -# See also: Application.show_config -# c.LabServerApp.show_config = False - -## Instead of starting the Application, dump configuration to stdout (as JSON) -# See also: Application.show_config_json -# c.LabServerApp.show_config_json = False - -## The optional location of local static files. If given, a static file handler -# will be added. -# Default: '' -# c.LabServerApp.static_dir = '' - -## paths to search for serving static files. -# See also: ExtensionApp.static_paths -# c.LabServerApp.static_paths = [] - -## Url where the static assets for the extension are served. -# See also: ExtensionApp.static_url_prefix -# c.LabServerApp.static_url_prefix = '' - -## Paths to search for serving jinja templates. -# See also: ExtensionApp.template_paths -# c.LabServerApp.template_paths = [] - -## The application templates directory. -# Default: '' -# c.LabServerApp.templates_dir = '' - -## The optional location of the themes directory. If given, a handler will be -# added for themes. -# Default: '' -# c.LabServerApp.themes_dir = '' - -## The theme url. -# Default: '' -# c.LabServerApp.themes_url = '' - -## The url path of the translations handler. -# Default: '' -# c.LabServerApp.translations_api_url = '' - -## The url path of the tree handler. -# Default: '' -# c.LabServerApp.tree_url = '' - -## The optional location of the user settings directory. -# Default: '' -# c.LabServerApp.user_settings_dir = '' - -## Deprecated, use `LabServerApp.allowed_extensions_uris` -# Default: '' -# c.LabServerApp.whitelist_uris = '' - -## The url path of the workspaces API. -# Default: '' -# c.LabServerApp.workspaces_api_url = '' - -## The optional location of the saved workspaces directory. If given, a handler -# will be added for workspaces. -# Default: '' -# c.LabServerApp.workspaces_dir = '' - -#------------------------------------------------------------------------------ -# LabApp(LabServerApp) configuration -#------------------------------------------------------------------------------ -## -# See also: LabServerApp.allowed_extensions_uris -# c.LabApp.allowed_extensions_uris = '' - -## Answer yes to any prompts. -# See also: JupyterApp.answer_yes -# c.LabApp.answer_yes = False - -## The app directory to launch JupyterLab from. -# Default: None -# c.LabApp.app_dir = None - -## The application settings directory. -# Default: '' -# c.LabApp.app_settings_dir = '' - -## The url path for the application. -# Default: '/lab' -# c.LabApp.app_url = '/lab' - -## Deprecated, use `LabServerApp.blocked_extensions_uris` -# See also: LabServerApp.blacklist_uris -# c.LabApp.blacklist_uris = '' - -## -# See also: LabServerApp.blocked_extensions_uris -# c.LabApp.blocked_extensions_uris = '' - -## Whether to cache files on the server. This should be `True` except in dev -# mode. -# Default: True -# c.LabApp.cache_files = True - -## A callable class that receives the current version at instantiation and -# calling it must return asynchronously a string indicating which version is -# available and how to install or None if no update is available. The string -# supports Markdown format. -# Default: 'jupyterlab.handlers.announcements.CheckForUpdate' -# c.LabApp.check_for_updates_class = 'jupyterlab.handlers.announcements.CheckForUpdate' - -## Whether to enable collaborative mode. -# Default: False -# c.LabApp.collaborative = False - -## Full path of a config file. -# See also: JupyterApp.config_file -# c.LabApp.config_file = '' - -## Specify a config file to load. -# See also: JupyterApp.config_file_name -# c.LabApp.config_file_name = '' - -## Whether to start the app in core mode. In this mode, JupyterLab -# will run using the JavaScript assets that are within the installed -# JupyterLab Python package. In core mode, third party extensions are disabled. -# The `--dev-mode` flag is an alias to this to be used when the Python package -# itself is installed in development mode (`pip install -e .`). -# Default: False -# c.LabApp.core_mode = False - ## The default URL to redirect to from `/` # Default: '/lab' c.LabApp.default_url = '/lab/tree/workshops/scipy2023/index.ipynb' -## Whether to start the app in dev mode. Uses the unpublished local -# JavaScript packages in the `dev_mode` folder. In this case JupyterLab will -# show a red stripe at the top of the page. It can only be used if JupyterLab -# is installed as `pip install -e .`. -# Default: False -# c.LabApp.dev_mode = False - -## Whether to expose the global app instance to browser via window.jupyterlab -# Default: False -# c.LabApp.expose_app_in_browser = False - -## Whether to load prebuilt extensions in dev mode. This may be -# useful to run and test prebuilt extensions in development installs of -# JupyterLab. APIs in a JupyterLab development install may be -# incompatible with published packages, so prebuilt extensions compiled -# against published packages may not work correctly. -# Default: False -# c.LabApp.extensions_in_dev_mode = False - -## Extra paths to look for federated JupyterLab extensions -# Default: [] -# c.LabApp.extra_labextensions_path = [] - -## Whether to skip loading styles for disabled prebuilt extensions. -# This will be the default behavior starting with JupyterLab 4.0 -# (and this flag will be removed). -# Default: False -# c.LabApp.future_skip_styles_for_disabled = False - -## Generate default config file. -# See also: JupyterApp.generate_config -# c.LabApp.generate_config = False - -## Handlers appended to the server. -# See also: ExtensionApp.handlers -# c.LabApp.handlers = [] - -## Options to pass to the jinja2 environment for this -# Default: {} -# c.LabApp.jinja2_options = {} - -## The standard paths to look in for federated JupyterLab extensions -# Default: [] -# c.LabApp.labextensions_path = [] - -## The url for federated JupyterLab extensions -# Default: '' -# c.LabApp.labextensions_url = '' - -## The interval delay in seconds to refresh the lists -# See also: LabServerApp.listings_refresh_seconds -# c.LabApp.listings_refresh_seconds = 3600 - -## The optional kwargs to use for the listings HTTP requests as -# described on https://2.python-requests.org/en/v2.7.0/api/#requests.request -# See also: LabServerApp.listings_request_options -# c.LabApp.listings_request_options = {} - -## The listings url. -# Default: '' -# c.LabApp.listings_url = '' - -## The date format used by logging formatters for %(asctime)s -# See also: Application.log_datefmt -# c.LabApp.log_datefmt = '%Y-%m-%d %H:%M:%S' - -## The Logging format template -# See also: Application.log_format -# c.LabApp.log_format = '[%(name)s]%(highlevel)s %(message)s' - -## Set the log level by value or name. -# See also: Application.log_level -# c.LabApp.log_level = 30 - -## -# See also: Application.logging_config -# c.LabApp.logging_config = {} - -## URL that serves news Atom feed; by default the JupyterLab organization -# announcements will be fetched. Set to None to turn off fetching announcements. -# Default: 'https://jupyterlab.github.io/assets/feed.xml' -# c.LabApp.news_url = 'https://jupyterlab.github.io/assets/feed.xml' - -## Whether a notebook should start a kernel automatically. -# Default: True -# c.LabApp.notebook_starts_kernel = True - -## Whether to open in a browser after starting. -# See also: ExtensionApp.open_browser -# c.LabApp.open_browser = False - -## The override url for static lab assets, typically a CDN. -# Default: '' -# c.LabApp.override_static_url = '' - -## The override url for static lab theme assets, typically a CDN. -# Default: '' -# c.LabApp.override_theme_url = '' - -## The optional location of the settings schemas directory. If given, a handler -# will be added for settings. -# Default: '' -# c.LabApp.schemas_dir = '' - -## Settings that will passed to the server. -# See also: ExtensionApp.settings -# c.LabApp.settings = {} - -## The url path of the settings handler. -# Default: '' -# c.LabApp.settings_url = '' - -## Instead of starting the Application, dump configuration to stdout -# See also: Application.show_config -# c.LabApp.show_config = False - -## Instead of starting the Application, dump configuration to stdout (as JSON) -# See also: Application.show_config_json -# c.LabApp.show_config_json = False - -## Splice source packages into app directory. -# Default: False -# c.LabApp.splice_source = False - -## The optional location of local static files. If given, a static file handler -# will be added. -# Default: '' -# c.LabApp.static_dir = '' - -## paths to search for serving static files. -# See also: ExtensionApp.static_paths -# c.LabApp.static_paths = [] - -## Url where the static assets for the extension are served. -# See also: ExtensionApp.static_url_prefix -# c.LabApp.static_url_prefix = '' - -## Paths to search for serving jinja templates. -# See also: ExtensionApp.template_paths -# c.LabApp.template_paths = [] - -## The application templates directory. -# Default: '' -# c.LabApp.templates_dir = '' - -## The optional location of the themes directory. If given, a handler will be -# added for themes. -# Default: '' -# c.LabApp.themes_dir = '' - -## The theme url. -# Default: '' -# c.LabApp.themes_url = '' - -## The url path of the translations handler. -# Default: '' -# c.LabApp.translations_api_url = '' - -## The url path of the tree handler. -# Default: '' -# c.LabApp.tree_url = '' - -## The directory for user settings. -# Default: '/Users/lsetiawan/.jupyter/lab/user-settings' -# c.LabApp.user_settings_dir = '/Users/lsetiawan/.jupyter/lab/user-settings' - -## Whether to serve the app in watch mode -# Default: False -# c.LabApp.watch = False - -## Deprecated, use `LabServerApp.allowed_extensions_uris` -# See also: LabServerApp.whitelist_uris -# c.LabApp.whitelist_uris = '' - -## The url path of the workspaces API. -# Default: '' -# c.LabApp.workspaces_api_url = '' - -## The directory for workspaces -# Default: '/Users/lsetiawan/.jupyter/lab/workspaces' -# c.LabApp.workspaces_dir = '/Users/lsetiawan/.jupyter/lab/workspaces' - -#------------------------------------------------------------------------------ -# ServerApp(JupyterApp) configuration -#------------------------------------------------------------------------------ -## The Jupyter Server application class. - -## Set the Access-Control-Allow-Credentials: true header -# Default: False -# c.ServerApp.allow_credentials = False - -## Set the Access-Control-Allow-Origin header -# -# Use '*' to allow any origin to access your server. -# -# Takes precedence over allow_origin_pat. -# Default: '' -# c.ServerApp.allow_origin = '' - -## Use a regular expression for the Access-Control-Allow-Origin header -# -# Requests from an origin matching the expression will get replies with: -# -# Access-Control-Allow-Origin: origin -# -# where `origin` is the origin of the request. -# -# Ignored if allow_origin is set. -# Default: '' -# c.ServerApp.allow_origin_pat = '' - -## DEPRECATED in 2.0. Use PasswordIdentityProvider.allow_password_change -# Default: True -# c.ServerApp.allow_password_change = True - -## Allow requests where the Host header doesn't point to a local server -# -# By default, requests get a 403 forbidden response if the 'Host' header -# shows that the browser thinks it's on a non-local domain. -# Setting this option to True disables this check. -# -# This protects against 'DNS rebinding' attacks, where a remote web server -# serves you a page and then changes its DNS to send later requests to a -# local IP, bypassing same-origin checks. -# -# Local IP addresses (such as 127.0.0.1 and ::1) are allowed as local, -# along with hostnames configured in local_hostnames. -# Default: False -# c.ServerApp.allow_remote_access = False - -## Whether to allow the user to run the server as root. -# Default: False -# c.ServerApp.allow_root = False - -## Answer yes to any prompts. -# See also: JupyterApp.answer_yes -# c.ServerApp.answer_yes = False - -## " -# Require authentication to access prometheus metrics. -# Default: True -# c.ServerApp.authenticate_prometheus = True - -## The authorizer class to use. -# Default: 'jupyter_server.auth.authorizer.AllowAllAuthorizer' -# c.ServerApp.authorizer_class = 'jupyter_server.auth.authorizer.AllowAllAuthorizer' - -## Reload the webapp when changes are made to any Python src files. -# Default: False -# c.ServerApp.autoreload = False - -## The base URL for the Jupyter server. -# -# Leading and trailing slashes can be omitted, -# and will automatically be added. -# Default: '/' -# c.ServerApp.base_url = '/' - -## Specify what command to use to invoke a web -# browser when starting the server. If not specified, the -# default browser will be determined by the `webbrowser` -# standard library module, which allows setting of the -# BROWSER environment variable to override it. -# Default: '' -# c.ServerApp.browser = '' - -## The full path to an SSL/TLS certificate file. -# Default: '' -# c.ServerApp.certfile = '' - -## The full path to a certificate authority certificate for SSL/TLS client -# authentication. -# Default: '' -# c.ServerApp.client_ca = '' - -## Full path of a config file. -# See also: JupyterApp.config_file -# c.ServerApp.config_file = '' - -## Specify a config file to load. -# See also: JupyterApp.config_file_name -# c.ServerApp.config_file_name = '' - -## The config manager class to use -# Default: 'jupyter_server.services.config.manager.ConfigManager' -# c.ServerApp.config_manager_class = 'jupyter_server.services.config.manager.ConfigManager' - -## The content manager class to use. -# Default: 'jupyter_server.services.contents.largefilemanager.AsyncLargeFileManager' -# c.ServerApp.contents_manager_class = 'jupyter_server.services.contents.largefilemanager.AsyncLargeFileManager' - -## DEPRECATED. Use IdentityProvider.cookie_options -# Default: {} -# c.ServerApp.cookie_options = {} - -## The random bytes used to secure cookies. -# By default this is a new random number every time you start the server. -# Set it to a value in a config file to enable logins to persist across server sessions. -# -# Note: Cookie secrets should be kept private, do not share config files with -# cookie_secret stored in plaintext (you can read the value from a file). -# Default: b'' -# c.ServerApp.cookie_secret = b'' - -## The file where the cookie secret is stored. -# Default: '' -# c.ServerApp.cookie_secret_file = '' - -## Override URL shown to users. -# -# Replace actual URL, including protocol, address, port and base URL, -# with the given value when displaying URL to the users. Do not change -# the actual connection URL. If authentication token is enabled, the -# token is added to the custom URL automatically. -# -# This option is intended to be used when the URL to display to the user -# cannot be determined reliably by the Jupyter server (proxified -# or containerized setups for example). -# Default: '' -# c.ServerApp.custom_display_url = '' - -## The default URL to redirect to from `/` -# Default: '/' -# c.ServerApp.default_url = '/' - -## Disable cross-site-request-forgery protection -# -# Jupyter server includes protection from cross-site request forgeries, -# requiring API requests to either: -# -# - originate from pages served by this server (validated with XSRF cookie and token), or -# - authenticate with a token -# -# Some anonymous compute resources still desire the ability to run code, -# completely without authentication. -# These services can disable all authentication and security checks, -# with the full knowledge of what that implies. -# Default: False -# c.ServerApp.disable_check_xsrf = False - -## handlers that should be loaded at higher priority than the default services -# Default: [] -# c.ServerApp.extra_services = [] - -## Extra paths to search for serving static files. -# -# This allows adding javascript/css to be available from the Jupyter server machine, -# or overriding individual files in the IPython -# Default: [] -# c.ServerApp.extra_static_paths = [] - -## Extra paths to search for serving jinja templates. -# -# Can be used to override templates from jupyter_server.templates. -# Default: [] -# c.ServerApp.extra_template_paths = [] - -## Open the named file when the application is launched. -# Default: '' -# c.ServerApp.file_to_run = '' - -## The URL prefix where files are opened directly. -# Default: 'notebooks' -# c.ServerApp.file_url_prefix = 'notebooks' - -## Generate default config file. -# See also: JupyterApp.generate_config -# c.ServerApp.generate_config = False - -## DEPRECATED. Use IdentityProvider.get_secure_cookie_kwargs -# Default: {} -# c.ServerApp.get_secure_cookie_kwargs = {} - -## The identity provider class to use. -# Default: 'jupyter_server.auth.identity.PasswordIdentityProvider' -# c.ServerApp.identity_provider_class = 'jupyter_server.auth.identity.PasswordIdentityProvider' - -## DEPRECATED. Use ZMQChannelsWebsocketConnection.iopub_data_rate_limit -# Default: 0.0 -# c.ServerApp.iopub_data_rate_limit = 0.0 - -## DEPRECATED. Use ZMQChannelsWebsocketConnection.iopub_msg_rate_limit -# Default: 0.0 -# c.ServerApp.iopub_msg_rate_limit = 0.0 - -## The IP address the Jupyter server will listen on. -# Default: 'localhost' -# c.ServerApp.ip = 'localhost' - -## Supply extra arguments that will be passed to Jinja environment. -# Default: {} -# c.ServerApp.jinja_environment_options = {} - -## Extra variables to supply to jinja templates when rendering. -# Default: {} -# c.ServerApp.jinja_template_vars = {} - -## Dict of Python modules to load as Jupyter server extensions.Entry values can -# be used to enable and disable the loading ofthe extensions. The extensions -# will be loaded in alphabetical order. -# Default: {} -# c.ServerApp.jpserver_extensions = {} - -## The kernel manager class to use. -# Default: 'jupyter_server.services.kernels.kernelmanager.MappingKernelManager' -# c.ServerApp.kernel_manager_class = 'jupyter_server.services.kernels.kernelmanager.MappingKernelManager' - -## The kernel spec manager class to use. Should be a subclass of -# `jupyter_client.kernelspec.KernelSpecManager`. -# -# The Api of KernelSpecManager is provisional and might change without warning -# between this version of Jupyter and the next stable one. -# Default: 'builtins.object' -# c.ServerApp.kernel_spec_manager_class = 'builtins.object' - -## The kernel websocket connection class to use. -# Default: 'jupyter_server.services.kernels.connection.channels.ZMQChannelsWebsocketConnection' -# c.ServerApp.kernel_websocket_connection_class = 'jupyter_server.services.kernels.connection.channels.ZMQChannelsWebsocketConnection' - -## DEPRECATED. Use ZMQChannelsWebsocketConnection.kernel_ws_protocol -# Default: '' -# c.ServerApp.kernel_ws_protocol = '' - -## The full path to a private key file for usage with SSL/TLS. -# Default: '' -# c.ServerApp.keyfile = '' - -## DEPRECATED. Use ZMQChannelsWebsocketConnection.limit_rate -# Default: False -# c.ServerApp.limit_rate = False - -## Hostnames to allow as local when allow_remote_access is False. -# -# Local IP addresses (such as 127.0.0.1 and ::1) are automatically accepted -# as local as well. -# Default: ['localhost'] -# c.ServerApp.local_hostnames = ['localhost'] - -## The date format used by logging formatters for %(asctime)s -# See also: Application.log_datefmt -# c.ServerApp.log_datefmt = '%Y-%m-%d %H:%M:%S' - -## The Logging format template -# See also: Application.log_format -# c.ServerApp.log_format = '[%(name)s]%(highlevel)s %(message)s' - -## Set the log level by value or name. -# See also: Application.log_level -# c.ServerApp.log_level = 30 - -## -# See also: Application.logging_config -# c.ServerApp.logging_config = {} - -## The login handler class to use. -# Default: 'jupyter_server.auth.login.LegacyLoginHandler' -# c.ServerApp.login_handler_class = 'jupyter_server.auth.login.LegacyLoginHandler' - -## The logout handler class to use. -# Default: 'jupyter_server.auth.logout.LogoutHandler' -# c.ServerApp.logout_handler_class = 'jupyter_server.auth.logout.LogoutHandler' - -## Sets the maximum allowed size of the client request body, specified in the -# Content-Length request header field. If the size in a request exceeds the -# configured value, a malformed HTTP message is returned to the client. -# -# Note: max_body_size is applied even in streaming mode. -# Default: 536870912 -# c.ServerApp.max_body_size = 536870912 - -## Gets or sets the maximum amount of memory, in bytes, that is allocated for use -# by the buffer manager. -# Default: 536870912 -# c.ServerApp.max_buffer_size = 536870912 - -## Gets or sets a lower bound on the open file handles process resource limit. -# This may need to be increased if you run into an OSError: [Errno 24] Too many -# open files. This is not applicable when running on Windows. -# Default: 0 -# c.ServerApp.min_open_files_limit = 0 - -## DEPRECATED, use root_dir. -# Default: '' -# c.ServerApp.notebook_dir = '' - -## Whether to open in a browser after starting. -# The specific browser used is platform dependent and -# determined by the python standard library `webbrowser` -# module, unless it is overridden using the --browser -# (ServerApp.browser) configuration option. -# Default: False -# c.ServerApp.open_browser = False - -## DEPRECATED in 2.0. Use PasswordIdentityProvider.hashed_password -# Default: '' -# c.ServerApp.password = '' - -## DEPRECATED in 2.0. Use PasswordIdentityProvider.password_required -# Default: False -# c.ServerApp.password_required = False - -## The port the server will listen on (env: JUPYTER_PORT). -# Default: 0 -# c.ServerApp.port = 0 - -## The number of additional ports to try if the specified port is not available -# (env: JUPYTER_PORT_RETRIES). -# Default: 50 -# c.ServerApp.port_retries = 50 - -## Preferred starting directory to use for notebooks and kernels. -# Default: '' -# c.ServerApp.preferred_dir = '' - -## DISABLED: use %pylab or %matplotlib in the notebook to enable matplotlib. -# Default: 'disabled' -# c.ServerApp.pylab = 'disabled' - -## If True, display controls to shut down the Jupyter server, such as menu items -# or buttons. -# Default: True -# c.ServerApp.quit_button = True - -## DEPRECATED. Use ZMQChannelsWebsocketConnection.rate_limit_window -# Default: 0.0 -# c.ServerApp.rate_limit_window = 0.0 - -## Reraise exceptions encountered loading server extensions? -# Default: False -# c.ServerApp.reraise_server_extension_failures = False - -## The directory to use for notebooks and kernels. -# Default: '' -# c.ServerApp.root_dir = '' - -## The session manager class to use. -# Default: 'builtins.object' -# c.ServerApp.session_manager_class = 'builtins.object' - -## Instead of starting the Application, dump configuration to stdout -# See also: Application.show_config -# c.ServerApp.show_config = False - -## Instead of starting the Application, dump configuration to stdout (as JSON) -# See also: Application.show_config_json -# c.ServerApp.show_config_json = False - -## Shut down the server after N seconds with no kernelsrunning and no activity. -# This can be used together with culling idle kernels -# (MappingKernelManager.cull_idle_timeout) to shutdown the Jupyter server when -# it's not in use. This is not precisely timed: it may shut down up to a minute -# later. 0 (the default) disables this automatic shutdown. -# Default: 0 -# c.ServerApp.shutdown_no_activity_timeout = 0 - -## The UNIX socket the Jupyter server will listen on. -# Default: '' -# c.ServerApp.sock = '' - -## The permissions mode for UNIX socket creation (default: 0600). -# Default: '0600' -# c.ServerApp.sock_mode = '0600' - -## Supply SSL options for the tornado HTTPServer. -# See the tornado docs for details. -# Default: {} -# c.ServerApp.ssl_options = {} - -## Supply overrides for terminado. Currently only supports "shell_command". -# Default: {} -# c.ServerApp.terminado_settings = {} - -## Set to False to disable terminals. -# -# This does *not* make the server more secure by itself. -# Anything the user can in a terminal, they can also do in a notebook. -# -# Terminals may also be automatically disabled if the terminado package -# is not available. -# Default: False -# c.ServerApp.terminals_enabled = False - -## DEPRECATED. Use IdentityProvider.token -# Default: '' -# c.ServerApp.token = '' - -## Supply overrides for the tornado.web.Application that the Jupyter server uses. -# Default: {} -# c.ServerApp.tornado_settings = {} - -## Whether to trust or not X-Scheme/X-Forwarded-Proto and X-Real-Ip/X-Forwarded- -# For headerssent by the upstream reverse proxy. Necessary if the proxy handles -# SSL -# Default: False -# c.ServerApp.trust_xheaders = False - -## Disable launching browser by redirect file -# For versions of notebook > 5.7.2, a security feature measure was added that -# prevented the authentication token used to launch the browser from being visible. -# This feature makes it difficult for other users on a multi-user system from -# running code in your Jupyter session as you. -# However, some environments (like Windows Subsystem for Linux (WSL) and Chromebooks), -# launching a browser using a redirect file can lead the browser failing to load. -# This is because of the difference in file structures/paths between the runtime and -# the browser. -# -# Disabling this setting to False will disable this behavior, allowing the browser -# to launch by using a URL and visible token (as before). -# Default: True -# c.ServerApp.use_redirect_file = True - -## Specify where to open the server on startup. This is the -# `new` argument passed to the standard library method `webbrowser.open`. -# The behaviour is not guaranteed, but depends on browser support. Valid -# values are: -# -# - 2 opens a new tab, -# - 1 opens a new window, -# - 0 opens in an existing window. -# -# See the `webbrowser.open` documentation for details. -# Default: 2 -# c.ServerApp.webbrowser_open_new = 2 - -## Set the tornado compression options for websocket connections. -# -# This value will be returned from -# :meth:`WebSocketHandler.get_compression_options`. None (default) will disable -# compression. A dict (even an empty one) will enable compression. -# -# See the tornado docs for WebSocketHandler.get_compression_options for details. -# Default: None -# c.ServerApp.websocket_compression_options = None - -## The base URL for websockets, -# if it differs from the HTTP server (hint: it almost certainly doesn't). -# -# Should be in the form of an HTTP origin: ws[s]://hostname[:port] -# Default: '' -# c.ServerApp.websocket_url = '' From 389973f69a02b9889e95338b9ddc02484b628df6 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Fri, 23 Jun 2023 00:27:16 +0000 Subject: [PATCH 20/36] [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --- .devcontainer/scipy2023/devcontainer.json | 39 ++++++++----------- .devcontainer/scipy2023/jupyter_lab_config.py | 3 +- workshops/scipy2023/README.md | 2 +- 3 files changed, 19 insertions(+), 25 deletions(-) diff --git a/.devcontainer/scipy2023/devcontainer.json b/.devcontainer/scipy2023/devcontainer.json index ed47b620..a60a7ecf 100644 --- a/.devcontainer/scipy2023/devcontainer.json +++ b/.devcontainer/scipy2023/devcontainer.json @@ -1,25 +1,20 @@ { - "build": { - "dockerfile": "../Dockerfile", - "context": "../../conda" + "build": { + "dockerfile": "../Dockerfile", + "context": "../../conda" + }, + "postCreateCommand": { + "juperlab": "mkdir /home/jovyan/.jupyter && cp .devcontainer/scipy2023/jupyter_lab_config.py /home/jovyan/.jupyter/jupyter_lab_config.py" + }, + "hostRequirements": { + "cpus": 2 + }, + "customizations": { + "codespaces": { + "openFiles": ["workshops/scipy2023/README.md"] }, - "postCreateCommand": { - "juperlab": "mkdir /home/jovyan/.jupyter && cp .devcontainer/scipy2023/jupyter_lab_config.py /home/jovyan/.jupyter/jupyter_lab_config.py" - }, - "hostRequirements": { - "cpus": 2 - }, - "customizations": { - "codespaces": { - "openFiles": [ - "workshops/scipy2023/README.md" - ] - }, - "vscode": { - "extensions": [ - "ms-toolsai.jupyter", - "ms-python.python" - ] - } + "vscode": { + "extensions": ["ms-toolsai.jupyter", "ms-python.python"] } -} \ No newline at end of file + } +} diff --git a/.devcontainer/scipy2023/jupyter_lab_config.py b/.devcontainer/scipy2023/jupyter_lab_config.py index 2d744134..da4df8f2 100644 --- a/.devcontainer/scipy2023/jupyter_lab_config.py +++ b/.devcontainer/scipy2023/jupyter_lab_config.py @@ -1,8 +1,7 @@ # Configuration file for lab. -c = get_config() #noqa +c = get_config() # noqa ## The default URL to redirect to from `/` # Default: '/lab' c.LabApp.default_url = '/lab/tree/workshops/scipy2023/index.ipynb' - diff --git a/workshops/scipy2023/README.md b/workshops/scipy2023/README.md index cfc17f94..a4e4e785 100644 --- a/workshops/scipy2023/README.md +++ b/workshops/scipy2023/README.md @@ -22,7 +22,7 @@ tutorial will be added soon. ## Github Codespaces This tutorial is available to run within github codespaces with the conda environment specification -in the [`conda-lock.yml`](../../conda/conda-lock.yml) file. +in the [`conda-lock.yml`](../../conda/conda-lock.yml) file. [![Open in GitHub Codespaces](https://github.com/codespaces/badge.svg)](https://github.com/codespaces/new/xarray-contrib/xarray-tutorial/tree/main?devcontainer_path=.devcontainer%2Fscipy2023%2Fdevcontainer.json) From f36571fa23a728828116ac5743ec96b3846f0786 Mon Sep 17 00:00:00 2001 From: Landung 'Don' Setiawan Date: Thu, 22 Jun 2023 17:32:04 -0700 Subject: [PATCH 21/36] Fix misspelling of jupyterlab --- .devcontainer/scipy2023/devcontainer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.devcontainer/scipy2023/devcontainer.json b/.devcontainer/scipy2023/devcontainer.json index a60a7ecf..2cd98bcc 100644 --- a/.devcontainer/scipy2023/devcontainer.json +++ b/.devcontainer/scipy2023/devcontainer.json @@ -4,7 +4,7 @@ "context": "../../conda" }, "postCreateCommand": { - "juperlab": "mkdir /home/jovyan/.jupyter && cp .devcontainer/scipy2023/jupyter_lab_config.py /home/jovyan/.jupyter/jupyter_lab_config.py" + "jupyterlab": "mkdir /home/jovyan/.jupyter && cp .devcontainer/scipy2023/jupyter_lab_config.py /home/jovyan/.jupyter/jupyter_lab_config.py" }, "hostRequirements": { "cpus": 2 From bfdf30e453f1c50f0bd8d7e8f50fbbd363a42943 Mon Sep 17 00:00:00 2001 From: Landung 'Don' Setiawan Date: Fri, 23 Jun 2023 08:16:21 -0700 Subject: [PATCH 22/36] Try to use tasks and predefined vars --- .devcontainer/scipy2023/devcontainer.json | 3 ++- .devcontainer/scipy2023/tasks.json | 18 ++++++++++++++++++ 2 files changed, 20 insertions(+), 1 deletion(-) create mode 100644 .devcontainer/scipy2023/tasks.json diff --git a/.devcontainer/scipy2023/devcontainer.json b/.devcontainer/scipy2023/devcontainer.json index 2cd98bcc..2377a332 100644 --- a/.devcontainer/scipy2023/devcontainer.json +++ b/.devcontainer/scipy2023/devcontainer.json @@ -4,7 +4,8 @@ "context": "../../conda" }, "postCreateCommand": { - "jupyterlab": "mkdir /home/jovyan/.jupyter && cp .devcontainer/scipy2023/jupyter_lab_config.py /home/jovyan/.jupyter/jupyter_lab_config.py" + "jupyterlab": "mkdir /home/jovyan/.jupyter && cp ${localWorkspaceFolder}/jupyter_lab_config.py /home/jovyan/.jupyter/jupyter_lab_config.py", + "vscode": "mkdir ${containerWorkspaceFolder}/.vscode && cp ${localWorkspaceFolder}/tasks.json ${containerWorkspaceFolder}/.vscode/tasks.json" }, "hostRequirements": { "cpus": 2 diff --git a/.devcontainer/scipy2023/tasks.json b/.devcontainer/scipy2023/tasks.json new file mode 100644 index 00000000..d1e345ae --- /dev/null +++ b/.devcontainer/scipy2023/tasks.json @@ -0,0 +1,18 @@ +{ + // See https://go.microsoft.com/fwlink/?LinkId=733558 + // for the documentation about the tasks.json format + "version": "2.0.0", + "tasks": [ + { + "label": "jupyterlab", + "type": "shell", + "command": "jupyter lab", + "presentation": { + "reveal": "always" + }, + "runOptions": { + "runOn": "folderOpen" + } + } + ] +} \ No newline at end of file From a1ca44095e7ac24887c7f9142c52ac3095490b25 Mon Sep 17 00:00:00 2001 From: Landung 'Don' Setiawan Date: Fri, 23 Jun 2023 08:26:50 -0700 Subject: [PATCH 23/36] Modify the paths to directories --- .devcontainer/scipy2023/devcontainer.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.devcontainer/scipy2023/devcontainer.json b/.devcontainer/scipy2023/devcontainer.json index 2377a332..353cfda4 100644 --- a/.devcontainer/scipy2023/devcontainer.json +++ b/.devcontainer/scipy2023/devcontainer.json @@ -4,8 +4,8 @@ "context": "../../conda" }, "postCreateCommand": { - "jupyterlab": "mkdir /home/jovyan/.jupyter && cp ${localWorkspaceFolder}/jupyter_lab_config.py /home/jovyan/.jupyter/jupyter_lab_config.py", - "vscode": "mkdir ${containerWorkspaceFolder}/.vscode && cp ${localWorkspaceFolder}/tasks.json ${containerWorkspaceFolder}/.vscode/tasks.json" + "jupyterlab": "mkdir /home/jovyan/.jupyter && cp ${containerWorkspaceFolder}/.devcontainer/scipy2023/jupyter_lab_config.py /home/jovyan/.jupyter/jupyter_lab_config.py", + "vscode": "mkdir ${containerWorkspaceFolder}/.vscode && cp ${containerWorkspaceFolder}/.devcontainer/scipy2023/tasks.json ${containerWorkspaceFolder}/.vscode/tasks.json" }, "hostRequirements": { "cpus": 2 From e5495519a9f067dbb53e9a9ad381f7e67caa904e Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Fri, 23 Jun 2023 15:30:57 +0000 Subject: [PATCH 24/36] [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --- .devcontainer/scipy2023/tasks.json | 34 +++++++++++++++--------------- 1 file changed, 17 insertions(+), 17 deletions(-) diff --git a/.devcontainer/scipy2023/tasks.json b/.devcontainer/scipy2023/tasks.json index d1e345ae..07f5bdd5 100644 --- a/.devcontainer/scipy2023/tasks.json +++ b/.devcontainer/scipy2023/tasks.json @@ -1,18 +1,18 @@ { - // See https://go.microsoft.com/fwlink/?LinkId=733558 - // for the documentation about the tasks.json format - "version": "2.0.0", - "tasks": [ - { - "label": "jupyterlab", - "type": "shell", - "command": "jupyter lab", - "presentation": { - "reveal": "always" - }, - "runOptions": { - "runOn": "folderOpen" - } - } - ] -} \ No newline at end of file + // See https://go.microsoft.com/fwlink/?LinkId=733558 + // for the documentation about the tasks.json format + "version": "2.0.0", + "tasks": [ + { + "label": "jupyterlab", + "type": "shell", + "command": "jupyter lab", + "presentation": { + "reveal": "always" + }, + "runOptions": { + "runOn": "folderOpen" + } + } + ] +} From b2924981f51e3bdfd277ef67d9b0b205c465acc5 Mon Sep 17 00:00:00 2001 From: Landung 'Don' Setiawan Date: Fri, 23 Jun 2023 08:38:41 -0700 Subject: [PATCH 25/36] Remove comments in tasks.json --- .devcontainer/scipy2023/tasks.json | 2 -- 1 file changed, 2 deletions(-) diff --git a/.devcontainer/scipy2023/tasks.json b/.devcontainer/scipy2023/tasks.json index 07f5bdd5..2785cc95 100644 --- a/.devcontainer/scipy2023/tasks.json +++ b/.devcontainer/scipy2023/tasks.json @@ -1,6 +1,4 @@ { - // See https://go.microsoft.com/fwlink/?LinkId=733558 - // for the documentation about the tasks.json format "version": "2.0.0", "tasks": [ { From 4b7ebae61c2940024fcc6c7f028933900ca81a62 Mon Sep 17 00:00:00 2001 From: Landung 'Don' Setiawan Date: Fri, 23 Jun 2023 08:45:33 -0700 Subject: [PATCH 26/36] Update readme to reflect recent changes --- workshops/scipy2023/README.md | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/workshops/scipy2023/README.md b/workshops/scipy2023/README.md index a4e4e785..56615c30 100644 --- a/workshops/scipy2023/README.md +++ b/workshops/scipy2023/README.md @@ -26,8 +26,10 @@ in the [`conda-lock.yml`](../../conda/conda-lock.yml) file. [![Open in GitHub Codespaces](https://github.com/codespaces/badge.svg)](https://github.com/codespaces/new/xarray-contrib/xarray-tutorial/tree/main?devcontainer_path=.devcontainer%2Fscipy2023%2Fdevcontainer.json) -Click the button above to launch the github codespaces. Once it's launched, a terminal will open. To use the Jupyter lab interface, simply run the command `jupyter lab` within the terminal to get the url, -at which point, you can click and open up the Jupyter lab interface. +☝️ Click the button above to launch the github codespaces. +Once it's launched, a terminal will open and it will execute `jupyter lab` automatically. +Once you see a url to click, simply `cmd + click` the given url. +This will open up another tab in your browser, leading to a Jupyter Lab Interface. ## Outline From f0f58acccb667ec54ed99757e8a98125511b7466 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Fri, 23 Jun 2023 15:47:41 +0000 Subject: [PATCH 27/36] [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --- workshops/scipy2023/README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/workshops/scipy2023/README.md b/workshops/scipy2023/README.md index 56615c30..9d0737e0 100644 --- a/workshops/scipy2023/README.md +++ b/workshops/scipy2023/README.md @@ -27,7 +27,7 @@ in the [`conda-lock.yml`](../../conda/conda-lock.yml) file. [![Open in GitHub Codespaces](https://github.com/codespaces/badge.svg)](https://github.com/codespaces/new/xarray-contrib/xarray-tutorial/tree/main?devcontainer_path=.devcontainer%2Fscipy2023%2Fdevcontainer.json) ☝️ Click the button above to launch the github codespaces. -Once it's launched, a terminal will open and it will execute `jupyter lab` automatically. +Once it's launched, a terminal will open and it will execute `jupyter lab` automatically. Once you see a url to click, simply `cmd + click` the given url. This will open up another tab in your browser, leading to a Jupyter Lab Interface. From 57f75963dcda6997e62581355ec5e6b2e0af3749 Mon Sep 17 00:00:00 2001 From: Landung 'Don' Setiawan Date: Fri, 23 Jun 2023 09:09:59 -0700 Subject: [PATCH 28/36] Update README --- workshops/scipy2023/README.md | 20 ++++++++++++++------ 1 file changed, 14 insertions(+), 6 deletions(-) diff --git a/workshops/scipy2023/README.md b/workshops/scipy2023/README.md index 9d0737e0..73347ed5 100644 --- a/workshops/scipy2023/README.md +++ b/workshops/scipy2023/README.md @@ -21,15 +21,23 @@ tutorial will be added soon. ## Github Codespaces -This tutorial is available to run within github codespaces with the conda environment specification -in the [`conda-lock.yml`](../../conda/conda-lock.yml) file. +This tutorial is available to run within [Github Codespaces](https://github.com/features/codespaces) - "a development environment that's hosted in the cloud" - with the conda environment specification in the [`conda-lock.yml`](../../conda/conda-lock.yml) file. [![Open in GitHub Codespaces](https://github.com/codespaces/badge.svg)](https://github.com/codespaces/new/xarray-contrib/xarray-tutorial/tree/main?devcontainer_path=.devcontainer%2Fscipy2023%2Fdevcontainer.json) -☝️ Click the button above to launch the github codespaces. -Once it's launched, a terminal will open and it will execute `jupyter lab` automatically. -Once you see a url to click, simply `cmd + click` the given url. -This will open up another tab in your browser, leading to a Jupyter Lab Interface. +☝️ Click the button above to go to options window to launch a Github codespace. + +A codespace is a development environment that's hosted in the cloud. +You can choose from a selection of virtual machine types: 2 cores - 4 GB RAM - 32 GB storage, and 4 cores - 8 GB RAM - 32GB storage. +Additionally, you are able to chose from various Dev container configuration, for this specific workshop, please ensure that `Scipy2023` is selected. +GitHub currently gives every user [120 vCPU hours per month for free](https://docs.github.com/en/billing/managing-billing-for-github-codespaces/about-billing-for-github-codespaces#monthly-included-storage-and-core-hours-for-personal-accounts), beyond that you must pay. **So be sure to explicitly stop or shut down your codespace when you are done by going to this page (https://github.com/codespaces/).** + +Once your codespace is launched, the following happens: + +- [Visual Studio Code](https://code.visualstudio.com/) Interface will open up within your browser. +- A built in terminal will open and it will execute `jupyter lab` automatically. +- Once you see a url to click within the terminal, simply `cmd + click` the given url. +- This will open up another tab in your browser, leading to a [Jupyter Lab](https://jupyterlab.readthedocs.io/en/latest/) Interface. ## Outline From 477b403744f2a8326f2ec8b3f9da91a12f496c7d Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Fri, 23 Jun 2023 16:10:19 +0000 Subject: [PATCH 29/36] [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --- workshops/scipy2023/README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/workshops/scipy2023/README.md b/workshops/scipy2023/README.md index 73347ed5..a9d9160f 100644 --- a/workshops/scipy2023/README.md +++ b/workshops/scipy2023/README.md @@ -34,8 +34,8 @@ GitHub currently gives every user [120 vCPU hours per month for free](https://do Once your codespace is launched, the following happens: -- [Visual Studio Code](https://code.visualstudio.com/) Interface will open up within your browser. -- A built in terminal will open and it will execute `jupyter lab` automatically. +- [Visual Studio Code](https://code.visualstudio.com/) Interface will open up within your browser. +- A built in terminal will open and it will execute `jupyter lab` automatically. - Once you see a url to click within the terminal, simply `cmd + click` the given url. - This will open up another tab in your browser, leading to a [Jupyter Lab](https://jupyterlab.readthedocs.io/en/latest/) Interface. From 9252985c807ff0feb8c2b04305c5af6b1ec43fdc Mon Sep 17 00:00:00 2001 From: Landung 'Don' Setiawan Date: Fri, 23 Jun 2023 09:13:09 -0700 Subject: [PATCH 30/36] Remove leading / --- workshops/scipy2023/README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/workshops/scipy2023/README.md b/workshops/scipy2023/README.md index a9d9160f..91816a2f 100644 --- a/workshops/scipy2023/README.md +++ b/workshops/scipy2023/README.md @@ -30,7 +30,7 @@ This tutorial is available to run within [Github Codespaces](https://github.com/ A codespace is a development environment that's hosted in the cloud. You can choose from a selection of virtual machine types: 2 cores - 4 GB RAM - 32 GB storage, and 4 cores - 8 GB RAM - 32GB storage. Additionally, you are able to chose from various Dev container configuration, for this specific workshop, please ensure that `Scipy2023` is selected. -GitHub currently gives every user [120 vCPU hours per month for free](https://docs.github.com/en/billing/managing-billing-for-github-codespaces/about-billing-for-github-codespaces#monthly-included-storage-and-core-hours-for-personal-accounts), beyond that you must pay. **So be sure to explicitly stop or shut down your codespace when you are done by going to this page (https://github.com/codespaces/).** +GitHub currently gives every user [120 vCPU hours per month for free](https://docs.github.com/en/billing/managing-billing-for-github-codespaces/about-billing-for-github-codespaces#monthly-included-storage-and-core-hours-for-personal-accounts), beyond that you must pay. **So be sure to explicitly stop or shut down your codespace when you are done by going to this page (https://github.com/codespaces).** Once your codespace is launched, the following happens: From 3da6dff1566b2d95002557a476856a7dbcc7eee1 Mon Sep 17 00:00:00 2001 From: Landung 'Don' Setiawan Date: Fri, 23 Jun 2023 09:20:51 -0700 Subject: [PATCH 31/36] Add dependabot to auto update dockerfile image version --- .github/dependabot.yml | 6 ++++++ 1 file changed, 6 insertions(+) create mode 100644 .github/dependabot.yml diff --git a/.github/dependabot.yml b/.github/dependabot.yml new file mode 100644 index 00000000..f2ff82d7 --- /dev/null +++ b/.github/dependabot.yml @@ -0,0 +1,6 @@ +version: 2 +updates: + - package-ecosystem: "docker" + directory: "/.devcontainer" + schedule: + interval: "daily" From 5b49dd8c38f46753e83a8dc5ace8572b59f35604 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Fri, 23 Jun 2023 16:21:08 +0000 Subject: [PATCH 32/36] [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --- .github/dependabot.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/dependabot.yml b/.github/dependabot.yml index f2ff82d7..a049e851 100644 --- a/.github/dependabot.yml +++ b/.github/dependabot.yml @@ -1,6 +1,6 @@ version: 2 updates: - - package-ecosystem: "docker" - directory: "/.devcontainer" + - package-ecosystem: 'docker' + directory: '/.devcontainer' schedule: - interval: "daily" + interval: 'daily' From 1ec923ebb7d02360e8d68483db6a008aba844484 Mon Sep 17 00:00:00 2001 From: Landung 'Don' Setiawan Date: Fri, 23 Jun 2023 09:31:19 -0700 Subject: [PATCH 33/36] Point to specific jupyter in conda --- .devcontainer/scipy2023/tasks.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.devcontainer/scipy2023/tasks.json b/.devcontainer/scipy2023/tasks.json index 2785cc95..c9633eb1 100644 --- a/.devcontainer/scipy2023/tasks.json +++ b/.devcontainer/scipy2023/tasks.json @@ -4,7 +4,7 @@ { "label": "jupyterlab", "type": "shell", - "command": "jupyter lab", + "command": "/srv/conda/envs/notebook/bin/jupyter lab", "presentation": { "reveal": "always" }, From 3247b34d1df24ada1a5e21783343e56feed1f6fe Mon Sep 17 00:00:00 2001 From: Landung 'Don' Setiawan Date: Fri, 23 Jun 2023 09:53:40 -0700 Subject: [PATCH 34/36] Allow all origins to avoid CORS --- .devcontainer/scipy2023/jupyter_lab_config.py | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/.devcontainer/scipy2023/jupyter_lab_config.py b/.devcontainer/scipy2023/jupyter_lab_config.py index da4df8f2..6a243b26 100644 --- a/.devcontainer/scipy2023/jupyter_lab_config.py +++ b/.devcontainer/scipy2023/jupyter_lab_config.py @@ -5,3 +5,11 @@ ## The default URL to redirect to from `/` # Default: '/lab' c.LabApp.default_url = '/lab/tree/workshops/scipy2023/index.ipynb' + +## Set the Access-Control-Allow-Origin header +# +# Use '*' to allow any origin to access your server. +# +# Takes precedence over allow_origin_pat. +# Default: '' +c.ServerApp.allow_origin = '*' From c9599f0ae76e581fe5daa2628f0c5e64aee23cc2 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Fri, 23 Jun 2023 16:53:58 +0000 Subject: [PATCH 35/36] [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --- .devcontainer/scipy2023/jupyter_lab_config.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.devcontainer/scipy2023/jupyter_lab_config.py b/.devcontainer/scipy2023/jupyter_lab_config.py index 6a243b26..0bdc1e31 100644 --- a/.devcontainer/scipy2023/jupyter_lab_config.py +++ b/.devcontainer/scipy2023/jupyter_lab_config.py @@ -7,9 +7,9 @@ c.LabApp.default_url = '/lab/tree/workshops/scipy2023/index.ipynb' ## Set the Access-Control-Allow-Origin header -# +# # Use '*' to allow any origin to access your server. -# +# # Takes precedence over allow_origin_pat. # Default: '' c.ServerApp.allow_origin = '*' From 3f987f69e0d792fb3438242b32ceb5e918083ddf Mon Sep 17 00:00:00 2001 From: Don Setiawan Date: Fri, 23 Jun 2023 10:40:46 -0700 Subject: [PATCH 36/36] Update .devcontainer/scipy2023/tasks.json Co-authored-by: Scott Henderson --- .devcontainer/scipy2023/tasks.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.devcontainer/scipy2023/tasks.json b/.devcontainer/scipy2023/tasks.json index c9633eb1..5660e45b 100644 --- a/.devcontainer/scipy2023/tasks.json +++ b/.devcontainer/scipy2023/tasks.json @@ -4,7 +4,7 @@ { "label": "jupyterlab", "type": "shell", - "command": "/srv/conda/envs/notebook/bin/jupyter lab", + "command": "/srv/conda/envs/notebook/bin/jupyter lab --no-browser", "presentation": { "reveal": "always" },