diff --git a/.github/workflows/release.yaml b/.github/workflows/release.yaml index e7c7c075ee0..4f6875756ea 100644 --- a/.github/workflows/release.yaml +++ b/.github/workflows/release.yaml @@ -4,7 +4,7 @@ on: workflow_dispatch: inputs: is_test: - description: 'Use Test Pypi' + description: "Use Test Pypi" required: true type: boolean default: true @@ -28,6 +28,9 @@ jobs: - name: Build dist run: | uv build + - name: Make docs + run: | + make docs - name: upload test distribution uses: pypa/gh-action-pypi-publish@release/v1 if: ${{ inputs.is_test }} diff --git a/.github/workflows/test.yaml b/.github/workflows/test.yaml index 8fe26022d95..8cbc956cb2c 100644 --- a/.github/workflows/test.yaml +++ b/.github/workflows/test.yaml @@ -191,6 +191,22 @@ jobs: - name: Run nox run: nox -e lint + trace-docs: + name: Trace docs + timeout-minutes: 10 + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v3 + - name: Setup Node.js + uses: actions/setup-node@v3 + with: + node-version: "20" + - name: Setup docs + run: make setup-docs-ci + - name: Run docs + run: make docs + trace-tests: name: Trace nox tests timeout-minutes: 10 diff --git a/Makefile b/Makefile new file mode 100644 index 00000000000..a53cde0a026 --- /dev/null +++ b/Makefile @@ -0,0 +1,17 @@ +.PHONY: docs build + +setup-docs-ci: + pip install -e .[docs] + playwright install + + cd docs && \ + npm install --global yarn && \ + npm install + +docs: + cd docs && make generate_all + +build: + uv build + +prepare-release: docs build \ No newline at end of file diff --git a/pyproject.toml b/pyproject.toml index 605ceabb8ed..2b237d75426 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -46,7 +46,7 @@ dependencies = [ ] [project.optional-dependencies] -trace_server = [] +docs = ["playwright", "lazydocs", "nbformat", "nbconvert"] anthropic = ["anthropic>=0.18.0"] cerebras = ["cerebras-cloud-sdk"] cohere = ["cohere>=5.9.1,<5.9.3"]