From 373275c30e9cb0c5d0435485287dad1329bf771f Mon Sep 17 00:00:00 2001 From: Beck <164545837+validbeck@users.noreply.github.com> Date: Fri, 15 May 2026 11:35:53 -0700 Subject: [PATCH 1/3] ci: Replace Poetry install step with uv setup Mirrors validmind/documentation#1328 commits c8adb07 + 1bb449b (final state: astral-sh/setup-uv@v5). Co-authored-by: Cursor --- .github/workflows/deploy-docs-prod.yaml | 6 ++---- .github/workflows/deploy-docs-staging.yaml | 6 ++---- .github/workflows/publish-llm-markdown.yaml | 6 ++---- .github/workflows/validate-docs-site.yaml | 6 ++---- 4 files changed, 8 insertions(+), 16 deletions(-) diff --git a/.github/workflows/deploy-docs-prod.yaml b/.github/workflows/deploy-docs-prod.yaml index 24697c2f30..6166d35080 100644 --- a/.github/workflows/deploy-docs-prod.yaml +++ b/.github/workflows/deploy-docs-prod.yaml @@ -75,10 +75,8 @@ jobs: with: version: ${{ vars.QUARTO_VERSION }} - - name: Install Poetry - run: | - curl -sSL https://install.python-poetry.org | python3 - - echo "$HOME/.local/bin" >> $GITHUB_PATH + - name: Set up uv + uses: astral-sh/setup-uv@v5 - name: Generate Python library docs run: | diff --git a/.github/workflows/deploy-docs-staging.yaml b/.github/workflows/deploy-docs-staging.yaml index 4c8f8fb69b..c5a36020b4 100644 --- a/.github/workflows/deploy-docs-staging.yaml +++ b/.github/workflows/deploy-docs-staging.yaml @@ -75,10 +75,8 @@ jobs: with: version: ${{ vars.QUARTO_VERSION }} - - name: Install Poetry - run: | - curl -sSL https://install.python-poetry.org | python3 - - echo "$HOME/.local/bin" >> $GITHUB_PATH + - name: Set up uv + uses: astral-sh/setup-uv@v5 - name: Generate Python library docs run: | diff --git a/.github/workflows/publish-llm-markdown.yaml b/.github/workflows/publish-llm-markdown.yaml index e5500fe568..0610dfcaa6 100644 --- a/.github/workflows/publish-llm-markdown.yaml +++ b/.github/workflows/publish-llm-markdown.yaml @@ -39,10 +39,8 @@ jobs: with: version: ${{ vars.QUARTO_VERSION }} - - name: Install Poetry - run: | - curl -sSL https://install.python-poetry.org | python3 - - echo "$HOME/.local/bin" >> $GITHUB_PATH + - name: Set up uv + uses: astral-sh/setup-uv@v5 - name: Generate Python library docs run: | diff --git a/.github/workflows/validate-docs-site.yaml b/.github/workflows/validate-docs-site.yaml index 309a7b302f..0ab4c54960 100644 --- a/.github/workflows/validate-docs-site.yaml +++ b/.github/workflows/validate-docs-site.yaml @@ -75,10 +75,8 @@ jobs: with: version: pre-release - - name: Install Poetry - run: | - curl -sSL https://install.python-poetry.org | python3 - - echo "$HOME/.local/bin" >> $GITHUB_PATH + - name: Set up uv + uses: astral-sh/setup-uv@v5 - name: Generate Python library docs run: | From 0afe9455d469e6c7d93cb0643131d600cef817ba Mon Sep 17 00:00:00 2001 From: Beck <164545837+validbeck@users.noreply.github.com> Date: Fri, 15 May 2026 11:36:43 -0700 Subject: [PATCH 2/3] Use uv for all Python script invocations Workflows: replace `pip install json-schema-for-humans` + bare `python` call with a single `uv run --with` invocation in deploy-docs-prod, deploy-docs-staging, and validate-docs-site. Makefile: switch every `python`, `pip`, and `poetry run` call to `uv run` (or `uv run --with` where deps are needed). Affects add-copyright, notebooks (sidebar updaters), template-schema-docs, test-descriptions, verify-copyright, and yearly-releases targets. Co-authored-by: Cursor --- .github/workflows/deploy-docs-prod.yaml | 3 +-- .github/workflows/deploy-docs-staging.yaml | 3 +-- .github/workflows/validate-docs-site.yaml | 3 +-- site/Makefile | 15 +++++++-------- 4 files changed, 10 insertions(+), 14 deletions(-) diff --git a/.github/workflows/deploy-docs-prod.yaml b/.github/workflows/deploy-docs-prod.yaml index 6166d35080..29f15535b5 100644 --- a/.github/workflows/deploy-docs-prod.yaml +++ b/.github/workflows/deploy-docs-prod.yaml @@ -89,8 +89,7 @@ jobs: - name: Generate template schema docs run: | - pip install json-schema-for-humans - BACKEND_ROOT=site/_source/backend python scripts/generate_template_schema_docs.py + BACKEND_ROOT=site/_source/backend uv run --with json-schema-for-humans python scripts/generate_template_schema_docs.py - name: Populate installation run: cp -r site/_source/installation/site/installation site/installation diff --git a/.github/workflows/deploy-docs-staging.yaml b/.github/workflows/deploy-docs-staging.yaml index c5a36020b4..d0750f2380 100644 --- a/.github/workflows/deploy-docs-staging.yaml +++ b/.github/workflows/deploy-docs-staging.yaml @@ -89,8 +89,7 @@ jobs: - name: Generate template schema docs run: | - pip install json-schema-for-humans - BACKEND_ROOT=site/_source/backend python scripts/generate_template_schema_docs.py + BACKEND_ROOT=site/_source/backend uv run --with json-schema-for-humans python scripts/generate_template_schema_docs.py - name: Populate installation run: cp -r site/_source/installation/site/installation site/installation diff --git a/.github/workflows/validate-docs-site.yaml b/.github/workflows/validate-docs-site.yaml index 0ab4c54960..91c1ed5ba9 100644 --- a/.github/workflows/validate-docs-site.yaml +++ b/.github/workflows/validate-docs-site.yaml @@ -89,8 +89,7 @@ jobs: - name: Generate template schema docs run: | - pip install json-schema-for-humans - BACKEND_ROOT=site/_source/backend python scripts/generate_template_schema_docs.py + BACKEND_ROOT=site/_source/backend uv run --with json-schema-for-humans python scripts/generate_template_schema_docs.py - name: Populate installation run: cp -r site/_source/installation/site/installation site/installation diff --git a/site/Makefile b/site/Makefile index d3372f286c..df2a4dbe37 100644 --- a/site/Makefile +++ b/site/Makefile @@ -59,7 +59,7 @@ help: add-copyright: @echo "\nAdding copyright headers to .qmd and .yml/.yaml files ..." - @cd .. && python site/scripts/add_copyright.py + @cd .. && uv run python site/scripts/add_copyright.py # Clean up source directory clean: @@ -337,9 +337,9 @@ notebooks: @echo "Copying _metadata.yml into notebooks/ ..." @cp developer/_metadata.yml $(DEST_DIR_NB)/_metadata.yml @echo "Updating developer/_sidebar.yaml with use_cases directories ..." - @python scripts/developer-sidebar/update_use_cases.py + @uv run python scripts/developer-sidebar/update_use_cases.py @echo "Updating developer/_sidebar.yaml with how-to directories ..." - @python scripts/developer-sidebar/update_how_tos.py + @uv run python scripts/developer-sidebar/update_how_tos.py @echo "Zip up notebooks.zip ..." @zip -r notebooks.zip $(DEST_DIR_NB) > /dev/null 2>&1 @@ -427,12 +427,11 @@ release-notes: template-schema-docs: @echo "\nGenerating template schema documentation ..." @if [ ! -d "$(SRC_ROOT)/backend" ]; then echo "Error: Backend not cloned. Run 'make clone' first."; exit 1; fi - @python -m pip install -q json-schema-for-humans - @BACKEND_ROOT=$(SRC_ROOT)/backend python ../scripts/generate_template_schema_docs.py + @BACKEND_ROOT=$(SRC_ROOT)/backend uv run --with json-schema-for-humans python ../scripts/generate_template_schema_docs.py test-descriptions: @echo "\nUpdating test descriptions source ..." - @cd _source/validmind-library && make install && poetry run python scripts/extract_descriptions.py validmind/tests + @cd _source/validmind-library && make install && uv run python scripts/extract_descriptions.py validmind/tests @cd ../../ @rm -rf $(DEST_DIR_TESTS) @mkdir -p $(DEST_DIR_TESTS) @@ -442,11 +441,11 @@ test-descriptions: verify-copyright: @echo "\nVerifying copyright headers in .qmd and .yml/.yaml files ..." - @cd .. && python site/scripts/verify_copyright_qmd.py + @cd .. && uv run python site/scripts/verify_copyright_qmd.py # Collate yearly releases yearly-releases: - @python ../release-scripts/yearly_cleanup.py + @uv run python ../release-scripts/yearly_cleanup.py cd ../ git status | grep -v 'release-scripts/' quarto preview From 8271eac6eb116e7c9634555ad690da519c5b813f Mon Sep 17 00:00:00 2001 From: Beck <164545837+validbeck@users.noreply.github.com> Date: Fri, 15 May 2026 12:17:31 -0700 Subject: [PATCH 3/3] Fixing copyright step order --- .github/workflows/validate-docs-site.yaml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/validate-docs-site.yaml b/.github/workflows/validate-docs-site.yaml index 91c1ed5ba9..1116bfae2a 100644 --- a/.github/workflows/validate-docs-site.yaml +++ b/.github/workflows/validate-docs-site.yaml @@ -65,6 +65,9 @@ jobs: src/backend/templates/documentation/model_documentation sparse-checkout-cone-mode: true + - name: Set up uv + uses: astral-sh/setup-uv@v5 + - name: Verify copyright headers run: | cd site @@ -75,9 +78,6 @@ jobs: with: version: pre-release - - name: Set up uv - uses: astral-sh/setup-uv@v5 - - name: Generate Python library docs run: | cd site/_source/validmind-library