From 8ffc358d08b3e974e8784640ae250d132239fb83 Mon Sep 17 00:00:00 2001 From: arjxn-py Date: Tue, 1 Apr 2025 18:06:58 +0530 Subject: [PATCH 1/4] Try creating single env --- .readthedocs.yaml | 29 ++++++++++++++--------------- docs/environment-docs.yml | 2 +- 2 files changed, 15 insertions(+), 16 deletions(-) diff --git a/.readthedocs.yaml b/.readthedocs.yaml index ff0f4adca..ed2e94efb 100644 --- a/.readthedocs.yaml +++ b/.readthedocs.yaml @@ -18,28 +18,27 @@ build: - SHELL=/bin/bash /bin/bash /tmp/micromamba-install.sh # Override the create_environment step (undocumented feature) to create - # multiple environments. + # a single environment instead of multiple environments. create_environment: # Pin micromamba - /bin/bash --login -c "micromamba self-update --version 2.0.7" - # Create the env for building the docs - - /bin/bash --login -c "micromamba env create -n jupytergis-docs -f docs/environment-docs.yml" - # Create the isolated env for building JupyterGIS - - /bin/bash --login -c "micromamba create -n jupytergis-build -c conda-forge nodejs hatch pip python=3.13" - - /bin/bash --login -c "micromamba run -n jupytergis-build pip install 'jupyterlab==4.3' 'datamodel-code-generator>=0.23.0'" + # Create a single environment that includes all dependencies + - /bin/bash --login -c "micromamba create -n jupytergis -c conda-forge nodejs hatch pip python=3.13" + - /bin/bash --login -c "micromamba run -n jupytergis pip install 'jupyterlab==4.3' 'datamodel-code-generator>=0.23.0'" + - /bin/bash --login -c "micromamba env update -n jupytergis -f docs/environment-docs.yml" - # Override the install step to do nothing - we already created the envs + # Override the install step to do nothing - we already created the env install: - - "echo 'Skipping! We already have the environments we need.'" + - "echo 'Skipping! We already have the environment we need.'" - # Before building the docs, build JupyterGIS in its isolated environment, - # then install the wheels into the docs environment. + # Before building the docs, build JupyterGIS in its environment, + # then install the wheels into the same environment. pre_build: - - /bin/bash --login -c "micromamba run -n jupytergis-build jlpm install" - - /bin/bash --login -c "micromamba run -n jupytergis-build jlpm build" - - /bin/bash --login -c "micromamba run -n jupytergis-build jlpm build:packages" + - /bin/bash --login -c "micromamba run -n jupytergis jlpm install" + - /bin/bash --login -c "micromamba run -n jupytergis jlpm build" + - /bin/bash --login -c "micromamba run -n jupytergis jlpm build:packages" - |- - /bin/bash --login -c "micromamba run -n jupytergis-docs \ + /bin/bash --login -c "micromamba run -n jupytergis \ python -m pip install \ $(ls ./python/jupytergis_core/dist/jupytergis*.whl) \ $(ls ./python/jupytergis_lab/dist/jupytergis*.whl) \ @@ -48,6 +47,6 @@ build: build: html: - |- - /bin/bash --login -c "cd docs && micromamba run -n jupytergis-docs \ + /bin/bash --login -c "cd docs && micromamba run -n jupytergis \ python -m sphinx --fail-on-warning --keep-going --nitpicky --show-traceback --builder html --doctree-dir _build/doctrees --define language=en . \ $READTHEDOCS_OUTPUT/html" diff --git a/docs/environment-docs.yml b/docs/environment-docs.yml index 28feb5133..0b32b0ee9 100644 --- a/docs/environment-docs.yml +++ b/docs/environment-docs.yml @@ -1,4 +1,4 @@ -name: jupytergis-docs +name: jupytergis channels: - conda-forge - nodefaults From c9c0ef1312ca868885dda243cf5cbdd4ba41d809 Mon Sep 17 00:00:00 2001 From: arjxn-py Date: Tue, 1 Apr 2025 18:24:36 +0530 Subject: [PATCH 2/4] try creating super env with yml --- .readthedocs.yaml | 10 ++++------ docs/environment-docs.yml | 9 ++++++--- 2 files changed, 10 insertions(+), 9 deletions(-) diff --git a/.readthedocs.yaml b/.readthedocs.yaml index ed2e94efb..0d95fbe16 100644 --- a/.readthedocs.yaml +++ b/.readthedocs.yaml @@ -20,12 +20,10 @@ build: # Override the create_environment step (undocumented feature) to create # a single environment instead of multiple environments. create_environment: - # Pin micromamba - - /bin/bash --login -c "micromamba self-update --version 2.0.7" - # Create a single environment that includes all dependencies - - /bin/bash --login -c "micromamba create -n jupytergis -c conda-forge nodejs hatch pip python=3.13" - - /bin/bash --login -c "micromamba run -n jupytergis pip install 'jupyterlab==4.3' 'datamodel-code-generator>=0.23.0'" - - /bin/bash --login -c "micromamba env update -n jupytergis -f docs/environment-docs.yml" + # Pin micromamba + - /bin/bash --login -c "micromamba self-update --version 2.0.7" + # Create the environment using the updated environment-docs.yml + - /bin/bash --login -c "micromamba env create -n jupytergis -f docs/environment-docs.yml" # Override the install step to do nothing - we already created the env install: diff --git a/docs/environment-docs.yml b/docs/environment-docs.yml index 0b32b0ee9..d5e196b60 100644 --- a/docs/environment-docs.yml +++ b/docs/environment-docs.yml @@ -4,9 +4,9 @@ channels: - nodefaults dependencies: - python=3.12 - - pip # Needed to install jupytergis wheels in RTD build - - # Build docs & JupyterLite + - pip + - nodejs + - hatch - jupyterlite-core - jupyterlite-xeus>=3.1.3,<4 - jupyterlite-sphinx @@ -18,3 +18,6 @@ dependencies: - sphinx-togglebutton - myst-parser - xeus-python # TODO: Do we need this? + - pip: + - jupyterlab==4.3 + - datamodel-code-generator>=0.23.0 From 1f27d3915b26fe86b194c6dbf26a64765f9c4ebd Mon Sep 17 00:00:00 2001 From: arjxn-py Date: Wed, 2 Apr 2025 16:46:33 +0530 Subject: [PATCH 3/4] env name -` jupytergis-docs` --- .readthedocs.yaml | 12 ++++++------ docs/environment-docs.yml | 2 +- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/.readthedocs.yaml b/.readthedocs.yaml index 0d95fbe16..7bd763518 100644 --- a/.readthedocs.yaml +++ b/.readthedocs.yaml @@ -23,7 +23,7 @@ build: # Pin micromamba - /bin/bash --login -c "micromamba self-update --version 2.0.7" # Create the environment using the updated environment-docs.yml - - /bin/bash --login -c "micromamba env create -n jupytergis -f docs/environment-docs.yml" + - /bin/bash --login -c "micromamba env create -n jupytergis-docs -f docs/environment-docs.yml" # Override the install step to do nothing - we already created the env install: @@ -32,11 +32,11 @@ build: # Before building the docs, build JupyterGIS in its environment, # then install the wheels into the same environment. pre_build: - - /bin/bash --login -c "micromamba run -n jupytergis jlpm install" - - /bin/bash --login -c "micromamba run -n jupytergis jlpm build" - - /bin/bash --login -c "micromamba run -n jupytergis jlpm build:packages" + - /bin/bash --login -c "micromamba run -n jupytergis-docs jlpm install" + - /bin/bash --login -c "micromamba run -n jupytergis-docs jlpm build" + - /bin/bash --login -c "micromamba run -n jupytergis-docs jlpm build:packages" - |- - /bin/bash --login -c "micromamba run -n jupytergis \ + /bin/bash --login -c "micromamba run -n jupytergis-docs \ python -m pip install \ $(ls ./python/jupytergis_core/dist/jupytergis*.whl) \ $(ls ./python/jupytergis_lab/dist/jupytergis*.whl) \ @@ -45,6 +45,6 @@ build: build: html: - |- - /bin/bash --login -c "cd docs && micromamba run -n jupytergis \ + /bin/bash --login -c "cd docs && micromamba run -n jupytergis-docs \ python -m sphinx --fail-on-warning --keep-going --nitpicky --show-traceback --builder html --doctree-dir _build/doctrees --define language=en . \ $READTHEDOCS_OUTPUT/html" diff --git a/docs/environment-docs.yml b/docs/environment-docs.yml index d5e196b60..c14c4eb25 100644 --- a/docs/environment-docs.yml +++ b/docs/environment-docs.yml @@ -1,4 +1,4 @@ -name: jupytergis +name: jupytergis-docs channels: - conda-forge - nodefaults From 16a32d40b8ca245ad051bbd8975401e5b39d8cf6 Mon Sep 17 00:00:00 2001 From: arjxn-py Date: Tue, 6 May 2025 20:53:49 +0530 Subject: [PATCH 4/4] Keeping env name `jupytergis` if it passes? --- docs/environment-docs.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/environment-docs.yml b/docs/environment-docs.yml index e6b2b95ea..9c118cc40 100644 --- a/docs/environment-docs.yml +++ b/docs/environment-docs.yml @@ -1,4 +1,4 @@ -name: jupytergis-docs +name: jupytergis channels: - conda-forge - nodefaults