Skip to content

Commit

Permalink
v2: Drop the vegafusion-jupyter package (#509)
Browse files Browse the repository at this point in the history
* Remove vegafusion-jupyter package

* port altair mock tests to use JupyterChart and

* relock, update pixi version in GA

* update ci

* install chrome, install test deps

* Don't run selenium tests on osx arm

* debugging

* disable selenium tests for windows

* remove unneeded windows deps

* comment other jobs

* add ipykernel

* fix selection

* restore all tests

* restore all tests

* comment out test with slider position issue
  • Loading branch information
jonmmease authored Sep 28, 2024
1 parent 903b2c4 commit a3f29c8
Show file tree
Hide file tree
Showing 53 changed files with 145 additions and 28,868 deletions.
148 changes: 49 additions & 99 deletions .github/workflows/build_test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ jobs:
uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # [email protected]
- uses: prefix-dev/[email protected]
with:
pixi-version: v0.27.1
pixi-version: v0.30.0
cache: true
- name: Cache
uses: actions/cache@v3
Expand Down Expand Up @@ -41,7 +41,7 @@ jobs:
uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # [email protected]
- uses: prefix-dev/[email protected]
with:
pixi-version: v0.27.1
pixi-version: v0.30.0
- name: Cache
uses: actions/cache@v3
with:
Expand Down Expand Up @@ -70,7 +70,7 @@ jobs:
uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # [email protected]
- uses: prefix-dev/[email protected]
with:
pixi-version: v0.27.1
pixi-version: v0.30.0
- name: Cache
uses: actions/cache@v3
with:
Expand Down Expand Up @@ -158,7 +158,7 @@ jobs:
uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # [email protected]
- uses: prefix-dev/[email protected]
with:
pixi-version: v0.27.1
pixi-version: v0.30.0
- name: Cache
uses: actions/cache@v3
with:
Expand All @@ -185,7 +185,7 @@ jobs:
uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # [email protected]
- uses: prefix-dev/[email protected]
with:
pixi-version: v0.27.1
pixi-version: v0.30.0
- name: Cache
uses: actions/cache@v3
with:
Expand All @@ -212,7 +212,7 @@ jobs:
uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # [email protected]
- uses: prefix-dev/[email protected]
with:
pixi-version: v0.27.1
pixi-version: v0.30.0
- name: Cache
uses: actions/cache@v3
with:
Expand All @@ -239,7 +239,7 @@ jobs:
uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # [email protected]
- uses: prefix-dev/[email protected]
with:
pixi-version: v0.27.1
pixi-version: v0.30.0
- name: Cache
uses: actions/cache@v3
with:
Expand All @@ -259,34 +259,6 @@ jobs:
python/vegafusion/dist/*.whl
python/vegafusion/dist/*.tar.gz
build-vegafusion-jupyter-packages:
runs-on: ubuntu-20.04
steps:
- name: Check out repository code
uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # [email protected]
- uses: prefix-dev/[email protected]
with:
pixi-version: v0.27.1
- name: Cache
uses: actions/cache@v3
with:
key: ${{ runner.os }}-${{ hashFiles('pixi.lock', 'Cargo.lock') }}-build-vegafusion-jupyter-packages
path: |
~/.cargo
target
.pixi
- name: Build vegafusion-jupyter wheel
run: |
echo JupyterLab Version: `pixi run jupyter-lab --version`
pixi run build-py-jupyter
- name: Upload artifacts
uses: actions/upload-artifact@0b7f8abb1508181956e8e162db84b466c27e18ce # [email protected]
with:
name: vegafusion-jupyter-packages
path: |
python/vegafusion-jupyter/dist/*.whl
python/vegafusion-jupyter/dist/*.tar.gz
test-vegafusion-python-linux-64:
runs-on: ubuntu-20.04
needs: [build-vegafusion-python-embed-linux-64, build-vegafusion-packages]
Expand All @@ -297,6 +269,10 @@ jobs:
uses: actions/setup-python@61a6322f88396a6271a6ee3565807d608ecaddd1 # [email protected]
with:
python-version: '3.11'
- name: Install Chrome
uses: browser-actions/setup-chrome@f0ff752add8c926994566c80b3ceadfd03f24d12 # pin@latest
with:
chrome-version: stable
- name: Install fonts on Linux
if: runner.os == 'Linux'
run: |
Expand All @@ -318,13 +294,27 @@ jobs:
ls -la
python -m pip install vegafusion-*.whl
python -m pip install vegafusion_python_embed-*manylinux_2_17_x86_64*.whl
python -m pip install pytest vega-datasets polars-lts-cpu "duckdb>=1.0" "vl-convert-python>=1.0.1rc1" scikit-image "pandas>=2.2"
# Optional dependencies
python -m pip install polars-lts-cpu "duckdb>=1.0" "vl-convert-python>=1.0.1rc1" scikit-image "pandas>=2.2" jupytext voila anywidget ipywidgets chromedriver-binary-auto
# Test dependencies
python -m pip install pytest vega-datasets scikit-image jupytext voila ipykernel anywidget ipywidgets selenium flaky tenacity chromedriver-binary-auto
- name: Test lazy imports
working-directory: python/vegafusion/
run: python checks/check_lazy_imports.py
- name: Test vegafusion
working-directory: python/vegafusion/
env:
VEGAFUSION_TEST_HEADLESS: 1
run: pytest
- name: Upload test artifacts
uses: actions/upload-artifact@0b7f8abb1508181956e8e162db84b466c27e18ce # [email protected]
if: always()
with:
name: vegafusion-python-test-failures
path: |
python/vegafusion/tests/output/*
test-vegafusion-python-osx-arm64:
runs-on: macos-14
Expand Down Expand Up @@ -352,10 +342,16 @@ jobs:
ls -la
python -m pip install vegafusion-*.whl
python -m pip install vegafusion_python_embed-*macosx_11_*_arm64.whl
python -m pip install pytest vega-datasets polars "duckdb>=1.0" vl-convert-python scikit-image "pandas>=2.2"
# Optional dependencies
python -m pip install polars "duckdb>=1.0" vl-convert-python "pandas>=2.2"
# Test dependencies
python -m pip install pytest vega-datasets scikit-image
- name: Test vegafusion
working-directory: python/vegafusion/
run: pytest
run: pytest --ignore=tests/test_altair_mocks.py

test-vegafusion-python-win-64:
runs-on: windows-2022
Expand All @@ -367,6 +363,10 @@ jobs:
uses: actions/setup-python@61a6322f88396a6271a6ee3565807d608ecaddd1 # [email protected]
with:
python-version: '3.8'
- name: Install Chrome
uses: browser-actions/setup-chrome@f0ff752add8c926994566c80b3ceadfd03f24d12 # pin@latest
with:
chrome-version: stable
- name: Download vegafusion-python-embed wheel
uses: actions/download-artifact@cbed621e49e4c01b044d60f6c80ea4ed6328b281 # pin@v2
with:
Expand All @@ -387,66 +387,16 @@ jobs:
python -m pip install $vegafusion
python -m pip install $vegafusion_python_embed
python -m pip install pytest pyarrow==10.0 altair==5.1.2 vega-datasets polars[timezone] "duckdb>=1.0" vl-convert-python scikit-image
# Optional dependencies
python -m pip install pyarrow==10.0 altair==5.1.2 polars[timezone] "duckdb>=1.0" vl-convert-python
# Test dependencies
python -m pip install pytest vega-datasets scikit-image
- name: Test vegafusion
working-directory: python/vegafusion/
run: pytest
run: pytest --ignore=tests/test_altair_mocks.py

test-vegafusion-jupyter-linux-64:
runs-on: ubuntu-20.04
needs:
- build-vegafusion-python-embed-linux-64
- build-vegafusion-packages
- build-vegafusion-jupyter-packages
steps:
- name: Check out repository code
uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # [email protected]
- uses: prefix-dev/[email protected]
with:
pixi-version: v0.27.1
- name: Cache
uses: actions/cache@v3
with:
key: ${{ runner.os }}-${{ hashFiles('pixi.lock', 'Cargo.lock') }}-test-vegafusion-jupyter-linux-64
path: |
.pixi
- name: Install Chrome
uses: browser-actions/setup-chrome@f0ff752add8c926994566c80b3ceadfd03f24d12 # pin@latest
with:
chrome-version: stable
- name: Download vegafusion-python-embed wheel
uses: actions/download-artifact@cbed621e49e4c01b044d60f6c80ea4ed6328b281 # pin@v2
with:
name: vegafusion-python-embed-wheels
path: target/wheels/
- name: Download vegafusion wheel
uses: actions/download-artifact@cbed621e49e4c01b044d60f6c80ea4ed6328b281 # pin@v2
with:
name: vegafusion-packages
path: target/wheels/
- name: Download vegafusion-jupyter wheel
uses: actions/download-artifact@cbed621e49e4c01b044d60f6c80ea4ed6328b281 # pin@v2
with:
name: vegafusion-jupyter-packages
path: target/wheels/
- name: install wheels
run: |
ls -la target/wheels/
pixi run pip install target/wheels/vegafusion_python_embed-*manylinux_2_17_x86_64*.whl
pixi run pip install target/wheels/vegafusion-*.whl
pixi run pip install target/wheels/vegafusion_jupyter-*.whl
pixi run pip install chromedriver-binary-auto
pixi run pip list
- name: Test vegafusion jupyter
run: |
VEGAFUSION_TEST_HEADLESS=1 pixi run pytest python/vegafusion-jupyter/tests
- name: Upload test artifacts
uses: actions/upload-artifact@0b7f8abb1508181956e8e162db84b466c27e18ce # [email protected]
if: always()
with:
name: vegafusion-jupyter-test-failures
path: |
python/vegafusion-jupyter/tests/failures/*

build-vegafusion-server-linux-64:
runs-on: ubuntu-20.04
Expand All @@ -455,7 +405,7 @@ jobs:
uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # [email protected]
- uses: prefix-dev/[email protected]
with:
pixi-version: v0.27.1
pixi-version: v0.30.0
- name: Cache
uses: actions/cache@v3
with:
Expand Down Expand Up @@ -564,7 +514,7 @@ jobs:
uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # [email protected]
- uses: prefix-dev/[email protected]
with:
pixi-version: v0.27.1
pixi-version: v0.30.0
- name: Cache
uses: actions/cache@v3
with:
Expand Down Expand Up @@ -596,7 +546,7 @@ jobs:
uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # [email protected]
- uses: prefix-dev/[email protected]
with:
pixi-version: v0.27.1
pixi-version: v0.30.0
- name: Cache
uses: actions/cache@v3
with:
Expand Down Expand Up @@ -627,7 +577,7 @@ jobs:
uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # [email protected]
- uses: prefix-dev/[email protected]
with:
pixi-version: v0.27.1
pixi-version: v0.30.0
- name: Cache
uses: actions/cache@v3
with:
Expand Down
7 changes: 6 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,14 @@
# More information here https://doc.rust-lang.org/cargo/guide/cargo-toml-vs-cargo-lock.html
Cargo.bak.lock

# vscode
.vscode/settings.json

# These are backup files generated by rustfmt
**/*.rs.bk

/python/vegafusion/tests/output/

vega-fusion/tests/scratch/*

vega-fusion/tests/util/vegajs_runtime/node_modules
Expand All @@ -19,7 +24,7 @@ vegafusion-runtime/tests/util/vegajs_runtime/node_modules/
/python/vegafusion-jupyter/vegafusion_jupyter/nbextension/
/.idea/
/python/vegafusion-jupyter/css/
/python/vegafusion-jupyter/tests/temp_screenshot/

_vegafusion_data
/python/vegafusion-jupyter/examples/data/
/python/vegafusion-jupyter/examples/omnisci_downloads/
Expand Down
6 changes: 0 additions & 6 deletions .vscode/settings.json

This file was deleted.

Loading

0 comments on commit a3f29c8

Please sign in to comment.