@@ -5,13 +5,16 @@ authors = [
55 " Ross Barnowski <rossbar@caltech.edu>" ,
66 " Kyle Sunden <git@ksunden.space>" ,
77]
8- channels = [" conda-forge" ]
8+ channels = [" https://repo.mamba.pm/emscripten-forge " , " conda-forge" ]
99description = " Add a short description here"
1010name = " executable-tutorials"
11- platforms = [" linux-64" , " osx-64" , " osx-arm64" , " win-64" ]
11+ platforms = [" linux-64" , " osx-64" , " osx-arm64" , " win-64" , " emscripten-wasm32 " ]
1212version = " 0.1.0"
1313
14- [tasks ]
14+ [feature .base ]
15+ platforms = [" linux-64" , " osx-64" , " osx-arm64" , " win-64" ]
16+
17+ [feature .base .tasks ]
1518build = { cmd = [
1619 " sphinx-build" ,
1720 " ." , # source directory
@@ -25,22 +28,23 @@ clean = "rm -rf _build/*"
2528start = " jupyter lab --FileContentsManager.preferred_dir tutorials"
2629test = " bash ./test.sh"
2730
28- [activation ]
31+ [feature . base . activation ]
2932# Workaround overrides JupyterLab configuration (at the environment level) to
3033# make double-clicking on a Jupytext Markdown file open that file as a
3134# notebook. This is important for the development workflow for contributors.
32- scripts = [" bash .binder/postBuild " ]
35+ scripts = [" activate.sh " ]
3336
34- [dependencies ]
37+ [feature . base . dependencies ]
3538python = " >=3.11"
3639matplotlib-base = " >=3.9"
37- ipympl = " >=0.9"
3840jupyterlab = " >=4.2"
3941jupyterlab-myst = " >=2.4"
4042pytest = " >=8.3.5,<9"
4143nbval = " >=0.11.0,<0.12"
44+ jupytext = " >=1.17.1,<2"
45+ ipympl = " >=0.9"
4246
43- [pypi-dependencies ]
47+ [feature . base . pypi-dependencies ]
4448sphinx = " >=8.0.2"
4549myst-nb = " >=1.1"
4650jupytext = " >=1.16"
@@ -49,19 +53,59 @@ sphinx-copybutton = ">=0.5"
4953sphinx-design = " *"
5054pytest-custom_exit_code = " *"
5155
56+ [feature .py312 ]
57+ platforms = [" linux-64" , " osx-64" , " osx-arm64" , " win-64" ]
58+
5259[feature .py312 .dependencies ]
5360python = " 3.12.*"
5461
62+ [feature .py313 ]
63+ platforms = [" linux-64" , " osx-64" , " osx-arm64" , " win-64" ]
64+
5565[feature .py313 .dependencies ]
5666python = " 3.13.*"
5767
58- [feature .jupyterlite .dependencies ]
68+ [feature .jupyterlite-runtime ]
69+ channels = [" https://repo.mamba.pm/emscripten-forge" , " conda-forge" ]
70+ platforms = [" emscripten-wasm32" ]
71+
72+ [feature .jupyterlite-runtime .dependencies ]
73+ xeus-python = " *"
74+ python = " >=3.11"
75+ matplotlib = " >=3.9"
76+ ipympl = " >=0.9"
77+ jupytext = " >=1.16"
78+
79+ [feature .jupyterlite-host ]
80+ channels = [" conda-forge" ]
81+ platforms = [" linux-64" , " osx-64" , " osx-arm64" , " win-64" ]
82+
83+ [feature .jupyterlite-host .dependencies ]
5984jupyterlab = " ~=4.2.4"
6085jupyterlite-core = " ==0.4.0"
61- jupyterlite-pyodide-kernel = " ==0.4.1 "
86+ jupyterlite-xeus = " * "
6287notebook = " ~=7.2.1"
88+ jupyterlab-myst = " >=2.4"
89+ jupytext = " >=1.16"
90+ ipympl = " >=0.9"
91+
92+ [feature .jupyterlite-host .tasks ]
93+ setup_wasm = {cmd = " pixi install -e jupyterlite-runtime" , inputs = [" pixi.lock" ]}
94+ convert_ipynbs = {cmd = " bash convert_all_jupyterlite.sh" , inputs = [" tutorials/" ], outputs = [" _build/ipynbs" ]}
95+
96+ [feature .jupyterlite-host .tasks .build_wasm ]
97+ cmd = " jupyter lite build --XeusAddon.prefix=.pixi/envs/jupyterlite-runtime --contents _build/ipynbs/tutorials --output-dir _build/html/jupyterlite --settings-overrides=.binder/overrides.json --log-level DEBUG"
98+ depends-on = [" setup_wasm" , " convert_ipynbs" ]
99+ outputs = [" _build/html/jupyterlite/" ]
100+ inputs = [" pixi.lock" , " tutorials/" ]
101+
102+ [feature .jupyterlite-host .tasks .start_wasm ]
103+ cmd = " python -m http.server 8000 -d _build/html/jupyterlite/"
104+ depends-on = [" build_wasm" ]
63105
64106[environments ]
65- py312 = [" py312" ]
66- py313 = [" py313" ]
67- jupyterlite = [" jupyterlite" ]
107+ default = [" base" ]
108+ py312 = [" base" , " py312" ]
109+ py313 = [" base" , " py313" ]
110+ jupyterlite-runtime = [" jupyterlite-runtime" ]
111+ jupyterlite-host = [" jupyterlite-host" ]
0 commit comments