Skip to content

Commit

Permalink
Merge branch 'main' into tree
Browse files Browse the repository at this point in the history
  • Loading branch information
philippjfr authored Jan 20, 2025
2 parents 3b5f675 + d323520 commit cc12be8
Show file tree
Hide file tree
Showing 596 changed files with 21,977 additions and 7,374 deletions.
26 changes: 19 additions & 7 deletions .github/workflows/build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ on:

defaults:
run:
shell: bash -el {0}
shell: bash -e {0}

env:
PACKAGE: "panel"
Expand All @@ -35,14 +35,14 @@ jobs:
name: Pixi lock
runs-on: ubuntu-latest
steps:
- uses: holoviz-dev/holoviz_tasks/pixi_lock@pixi
- uses: holoviz-dev/holoviz_tasks/pixi_lock@v0

conda_build:
name: Build Conda
needs: [pixi_lock]
runs-on: "ubuntu-latest"
steps:
- uses: holoviz-dev/holoviz_tasks/pixi_install@pixi
- uses: holoviz-dev/holoviz_tasks/pixi_install@v0
with:
environments: "build"
install: false
Expand All @@ -55,12 +55,17 @@ jobs:
name: conda
path: dist/*tar.bz2
if-no-files-found: error
- name: Verify size
run: python scripts/verify_build_size.py conda

conda_publish:
name: Publish Conda
runs-on: ubuntu-latest
needs: [conda_build, waiting_room]
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags/')
defaults:
run:
shell: bash -el {0}
steps:
- uses: actions/download-artifact@v4
with:
Expand All @@ -73,6 +78,7 @@ jobs:
- uses: conda-incubator/setup-miniconda@v3
with:
miniconda-version: "latest"
channels: "conda-forge"
- name: conda setup
run: |
conda install -y anaconda-client
Expand All @@ -90,7 +96,7 @@ jobs:
needs: [pixi_lock]
runs-on: "ubuntu-latest"
steps:
- uses: holoviz-dev/holoviz_tasks/pixi_install@pixi
- uses: holoviz-dev/holoviz_tasks/pixi_install@v0
with:
environments: "build"
install: false
Expand All @@ -103,6 +109,10 @@ jobs:
name: pip
path: dist/
if-no-files-found: error
- name: Verify sizes
run: |
python scripts/verify_build_size.py sdist
python scripts/verify_build_size.py whl
pip_install:
name: Install PyPI
Expand All @@ -119,7 +129,7 @@ jobs:
- name: Install package
run: python -m pip install dist/*.whl
- name: Test package
run: python -c "import $PACKAGE; print($PACKAGE.__version__)"
run: python -c "import $PACKAGE; print($PACKAGE._version.__version__)"

pip_publish:
name: Publish PyPI
Expand All @@ -143,7 +153,7 @@ jobs:
needs: [pixi_lock]
runs-on: "ubuntu-latest"
steps:
- uses: holoviz-dev/holoviz_tasks/pixi_install@pixi
- uses: holoviz-dev/holoviz_tasks/pixi_install@v0
with:
environments: "build"
download-data: false
Expand All @@ -162,6 +172,8 @@ jobs:
name: npm
if-no-files-found: error
path: ./${{ env.PACKAGE }}/${{ env.TARBALL }}
- name: Verify size
run: python scripts/verify_build_size.py npm

npm_publish:
name: Publish NPM
Expand Down Expand Up @@ -198,7 +210,7 @@ jobs:
needs: [pixi_lock]
runs-on: "ubuntu-latest"
steps:
- uses: holoviz-dev/holoviz_tasks/pixi_install@pixi
- uses: holoviz-dev/holoviz_tasks/pixi_install@v0
with:
environments: "build"
install: false
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/docs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ on:

defaults:
run:
shell: bash -el {0}
shell: bash -e {0}

env:
DISPLAY: ":99.0"
Expand All @@ -33,7 +33,7 @@ jobs:
name: Pixi lock
runs-on: ubuntu-latest
steps:
- uses: holoviz-dev/holoviz_tasks/pixi_lock@pixi
- uses: holoviz-dev/holoviz_tasks/pixi_lock@v0

docs_build:
name: Build Documentation
Expand All @@ -43,7 +43,7 @@ jobs:
outputs:
tag: ${{ steps.vars.outputs.tag }}
steps:
- uses: holoviz-dev/holoviz_tasks/pixi_install@pixi
- uses: holoviz-dev/holoviz_tasks/pixi_install@v0
with:
environments: docs
opengl: true
Expand Down
8 changes: 5 additions & 3 deletions .github/workflows/gallery.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ jobs:
runs-on: ubuntu-latest
defaults:
run:
shell: bash -l {0}
shell: bash -el {0}
steps:
- name: Checkout
uses: actions/checkout@v3
Expand All @@ -35,9 +35,11 @@ jobs:
python-version: '3.10'
- name: Set and echo git ref
id: vars
env:
HEAD_BRANCH: ${{ github.event.workflow_run.head_branch }}
run: |
echo 'Deploying from ref ${{ github.event.workflow_run.head_branch }}'
echo 'tag=${{ github.event.workflow_run.head_branch }}' >> $GITHUB_OUTPUT
echo "Deploying from ref $HEAD_BRANCH"
echo "tag=$HEAD_BRANCH" >> $GITHUB_OUTPUT
- uses: conda-incubator/setup-miniconda@v2
with:
miniconda-version: "latest"
Expand Down
78 changes: 43 additions & 35 deletions .github/workflows/jupyterlite.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,59 +3,67 @@ name: jupyterlite
on:
push:
tags:
- 'v[0-9]+.[0-9]+.[0-9]+'
- 'v[0-9]+.[0-9]+.[0-9]+a[0-9]+'
- 'v[0-9]+.[0-9]+.[0-9]+b[0-9]+'
- 'v[0-9]+.[0-9]+.[0-9]+rc[0-9]+'
- "v[0-9]+.[0-9]+.[0-9]+"
- "v[0-9]+.[0-9]+.[0-9]+a[0-9]+"
- "v[0-9]+.[0-9]+.[0-9]+b[0-9]+"
- "v[0-9]+.[0-9]+.[0-9]+rc[0-9]+"
workflow_dispatch:
inputs:
target:
description: 'Site to build and deploy'
description: "Site to build and deploy"
type: choice
options:
- dev
- main
- dryrun
- dev
- main
- dryrun
required: true
default: dryrun
schedule:
- cron: '0 19 * * SUN'
- cron: "0 19 * * SUN"

jobs:
deploy_jupyterlite:
name: JupyterLite
pixi_lock:
name: Pixi lock
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
- uses: holoviz-dev/holoviz_tasks/pixi_lock@v0

lite_build:
name: Build Jupyterlite
needs: [pixi_lock]
runs-on: "ubuntu-latest"
steps:
- uses: holoviz-dev/holoviz_tasks/pixi_install@v0
with:
environments: "lite"
install: false
download-data: false
- name: lite build
run: pixi run lite-build
- uses: actions/upload-artifact@v4
if: always()
with:
fetch-depth: 0
- name: Setup Python
uses: actions/setup-python@v4
name: jupyterlite
path: lite/dist/
if-no-files-found: error

lite_publish:
name: Publish Jupyterlite
runs-on: ubuntu-latest
needs: [lite_build]
steps:
- uses: actions/download-artifact@v4
with:
python-version: '3.10'
- name: Set and echo git ref
name: jupyterlite
path: lite/dist/
- name: Set output
id: vars
run: |
echo 'Deploying from ref ${GITHUB_REF#refs/*/}'
echo 'tag=${GITHUB_REF#refs/*/}' >> $GITHUB_OUTPUT
- name: Install the dependencies
run: |
python -m pip install -r ./lite/requirements.txt
- name: Build pyodide wheels for JupyterLite
run: |
python ./scripts/build_pyodide_wheels.py lite/pypi
- name: Convert content
run: |
python ./scripts/panelite/generate_panelite_content.py
- name: Build the JupyterLite site
run: |
jupyter lite build --lite-dir lite --output-dir lite/dist
run: echo "tag=${{ needs.docs_build.outputs.tag }}" >> $GITHUB_OUTPUT
- name: Upload dev
if: |
(github.event_name == 'workflow_dispatch' && github.event.inputs.target == 'dev') ||
(github.event_name == 'workflow_run' && (contains(steps.vars.outputs.tag, 'a') || contains(steps.vars.outputs.tag, 'b') || contains(steps.vars.outputs.tag, 'rc')))
uses: peaceiris/actions-gh-pages@v3
uses: peaceiris/actions-gh-pages@v4
with:
personal_token: ${{ secrets.ACCESS_TOKEN }}
external_repository: holoviz-dev/panelite-dev
Expand All @@ -65,7 +73,7 @@ jobs:
if: |
(github.event_name == 'workflow_dispatch' && github.event.inputs.target == 'main') ||
(github.event_name == 'push' && !(contains(steps.vars.outputs.tag, 'a') || contains(steps.vars.outputs.tag, 'b') || contains(steps.vars.outputs.tag, 'rc')))
uses: peaceiris/actions-gh-pages@v3
uses: peaceiris/actions-gh-pages@v4
with:
personal_token: ${{ secrets.ACCESS_TOKEN }}
external_repository: holoviz-dev/panelite
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/nightly_lock.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ jobs:
runs-on: ubuntu-latest
timeout-minutes: 5
steps:
- uses: holoviz-dev/holoviz_tasks/pixi_lock@pixi
- uses: holoviz-dev/holoviz_tasks/pixi_lock@v0
- name: Upload lock-file to S3
if: '!github.event.pull_request.head.repo.fork'
env:
Expand Down
58 changes: 42 additions & 16 deletions .github/workflows/test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ concurrency:

defaults:
run:
shell: bash -el {0}
shell: bash -e {0}

env:
DISPLAY: ":99.0"
Expand Down Expand Up @@ -125,7 +125,7 @@ jobs:
name: Pixi lock
runs-on: ubuntu-latest
steps:
- uses: holoviz-dev/holoviz_tasks/pixi_lock@pixi
- uses: holoviz-dev/holoviz_tasks/pixi_lock@v0
with:
cache: ${{ github.event.inputs.cache == 'true' || github.event.inputs.cache == '' }}

Expand All @@ -137,9 +137,9 @@ jobs:
strategy:
fail-fast: false
matrix: ${{ fromJson(needs.setup.outputs.matrix) }}
timeout-minutes: 90
timeout-minutes: 30
steps:
- uses: holoviz-dev/holoviz_tasks/pixi_install@pixi
- uses: holoviz-dev/holoviz_tasks/pixi_install@v0
with:
environments: ${{ matrix.environment }}
opengl: true
Expand Down Expand Up @@ -193,23 +193,20 @@ jobs:
OKTA_OAUTH_USER: ${{ secrets.OKTA_OAUTH_USER }}
OKTA_OAUTH_PASSWORD: ${{ secrets.OKTA_OAUTH_PASSWORD }}
steps:
- uses: holoviz-dev/holoviz_tasks/pixi_install@pixi
- uses: holoviz-dev/holoviz_tasks/pixi_install@v0
with:
environments: ${{ matrix.environment }}
id: install
- name: Build pyodide wheels
run: pixi run -e test-ui "python ./scripts/build_pyodide_wheels.py"
- name: Launch JupyterLab
shell: pixi run -e test-ui bash -el {0}
shell: pixi run -e test-ui bash -e {0}
run: |
jupyter server extension enable panel.io.jupyter_server_extension --sys-prefix
(jupyter lab --config panel/tests/ui/jupyter_server_test_config.py --port 8887 > /tmp/jupyterlab_server.log 2>&1) &
- name: Build JupyterLite
shell: pixi run -e test-ui bash -el {0}
run: |
# TODO: Make this a pixi feature/environment
python -m pip install -r ./lite/requirements.txt
python ./scripts/build_pyodide_wheels.py lite/pypi
python ./scripts/panelite/generate_panelite_content.py
jupyter lite build --lite-dir lite --output-dir lite/dist
shell: pixi run -e test-ui bash -e {0}
run: pixi run -e lite lite-build
- name: Wait for JupyterLab
uses: ifaxity/[email protected]
with:
Expand All @@ -230,7 +227,7 @@ jobs:
if-no-files-found: ignore
- name: Stop JupyterLab
if: always()
shell: pixi run -e test-ui bash -el {0}
shell: pixi run -e test-ui bash -e {0}
run: |
jupyter lab stop 8887 || true
- uses: codecov/codecov-action@v4
Expand All @@ -246,12 +243,41 @@ jobs:
fail-fast: false
matrix:
os: ["ubuntu-latest"]
environment: ["test-core"]
environment: ["test-core", "test-minimum"]
timeout-minutes: 120
steps:
- uses: holoviz-dev/holoviz_tasks/pixi_install@pixi
- uses: holoviz-dev/holoviz_tasks/pixi_install@v0
with:
environments: ${{ matrix.environment }}
- name: Test Unit
run: |
pixi run -e ${{ matrix.environment }} test-unit
type_test_suite:
name: type:${{ matrix.environment }}:${{ matrix.os }}
needs: [pre_commit, setup, pixi_lock]
runs-on: ${{ matrix.os }}
if: needs.setup.outputs.code_change == 'true'
strategy:
fail-fast: false
matrix:
os: ["ubuntu-latest"]
environment: ["test-type"]
timeout-minutes: 120
steps:
- uses: holoviz-dev/holoviz_tasks/pixi_install@v0
with:
environments: ${{ matrix.environment }}
- name: Test Type
run: |
pixi run -e ${{ matrix.environment }} test-type
result_test_suite:
name: result:test
needs: [unit_test_suite, ui_test_suite, core_test_suite, type_test_suite]
if: always()
runs-on: ubuntu-latest
steps:
- name: check for failures
if: contains(needs.*.result, 'failure') || contains(needs.*.result, 'cancelled')
run: echo job failed && exit 1
Loading

0 comments on commit cc12be8

Please sign in to comment.