Skip to content

add desktop-only CI, add py312, remove ipywidgets import in plot.py, pin pygfx>=0.1.14 #314

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Oct 3, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
73 changes: 65 additions & 8 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,10 +22,10 @@ jobs:
fail-fast: false
steps:
- uses: actions/checkout@v3
- name: Set up Python 3.9
- name: Set up Python 3.11
uses: actions/setup-python@v4
with:
python-version: 3.9
python-version: 3.11
- name: Install llvmpipe and lavapipe for offscreen canvas, and git lfs
run: |
sudo apt-get update -y -qq
Expand All @@ -36,8 +36,8 @@ jobs:
sudo apt-get install ./pandoc-3.1.4-1-amd64.deb
- name: Install dev dependencies
run: |
python -m pip install --upgrade pip
# remove pygfx from requirements, we install a specific commit of pygfx since both fpl and pygfx are fast evolving
python -m pip install --upgrade pip setuptools
# remove pygfx from install_requires, we install using pygfx@main
sed -i "/pygfx/d" ./setup.py
pip install git+https://github.com/pygfx/pygfx.git@main
pip install -e ".[notebook,docs,tests]"
Expand All @@ -46,8 +46,8 @@ jobs:
cd docs
make html SPHINXOPTS="-W --keep-going"

test-build:
name: Test examples
test-build-full:
name: Test examples, env with notebook and glfw
runs-on: ubuntu-latest
if: ${{ !github.event.pull_request.draft }}
strategy:
Expand All @@ -60,6 +60,8 @@ jobs:
pyversion: '3.10'
- name: Test py311
pyversion: '3.11'
- name: Test py312
pyversion: '3.12'
steps:
- name: Install git-lfs
run: |
Expand All @@ -75,8 +77,8 @@ jobs:
sudo apt-get install --no-install-recommends -y libegl1-mesa libgl1-mesa-dri libxcb-xfixes0-dev mesa-vulkan-drivers git-lfs
- name: Install dev dependencies
run: |
python -m pip install --upgrade pip
# remove pygfx from requirements, we install a specific commit of pygfx since both fpl and pygfx are fast evolving
python -m pip install --upgrade pip setuptools
# remove pygfx from install_requires, we install using pygfx@main
sed -i "/pygfx/d" ./setup.py
pip install git+https://github.com/pygfx/pygfx.git@main
pip install -e ".["tests"]"
Expand All @@ -100,3 +102,58 @@ jobs:
path: |
examples/desktop/diffs
examples/notebooks/diffs

test-build-desktop:
name: Test examples, env with only glfw
runs-on: ubuntu-latest
if: ${{ !github.event.pull_request.draft }}
strategy:
fail-fast: false
matrix:
include:
- name: Test py39
pyversion: '3.9'
- name: Test py310
pyversion: '3.10'
- name: Test py311
pyversion: '3.11'
- name: Test py312
pyversion: '3.12'
steps:
- name: Install git-lfs
run: |
sudo apt install --no-install-recommends -y git-lfs
- uses: actions/checkout@v3
- name: Set up Python
uses: actions/setup-python@v3
with:
python-version: ${{ matrix.pyversion }}
- name: Install llvmpipe and lavapipe for offscreen canvas
run: |
sudo apt-get update -y -qq
sudo apt-get install --no-install-recommends -y libegl1-mesa libgl1-mesa-dri libxcb-xfixes0-dev mesa-vulkan-drivers git-lfs
- name: Install dev dependencies
run: |
python -m pip install --upgrade pip setuptools
# remove pygfx from install_requires, we install using pygfx@main
sed -i "/pygfx/d" ./setup.py
pip install git+https://github.com/pygfx/pygfx.git@main
pip install -e ".["tests-desktop"]"
- name: Show wgpu backend
run:
python -c "from examples.tests.testutils import wgpu_backend; print(wgpu_backend)"
- name: fetch git lfs files
run: |
git lfs fetch --all
git lfs pull
- name: Test examples
env:
PYGFX_EXPECT_LAVAPIPE: true
run: |
pytest -v examples
- uses: actions/upload-artifact@v3
if: ${{ failure() }}
with:
name: screenshot-diffs
path: |
examples/desktop/diffs
2 changes: 1 addition & 1 deletion .github/workflows/pypi-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ jobs:
- name: Set up Python
uses: actions/setup-python@v3
with:
python-version: '3.x'
python-version: '3.10'
- name: Install dependencies
run: |
python -m pip install --upgrade pip
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/screenshots.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,18 +20,18 @@ jobs:
run: |
sudo apt install --no-install-recommends -y git-lfs
- uses: actions/checkout@v3
- name: Set up Python 3.10
- name: Set up Python 3.11
uses: actions/setup-python@v4
with:
python-version: '3.10'
python-version: '3.11'
- name: Install llvmpipe and lavapipe for offscreen canvas
run: |
sudo apt-get update -y -qq
sudo apt-get install --no-install-recommends -y libegl1-mesa libgl1-mesa-dri libxcb-xfixes0-dev mesa-vulkan-drivers
- name: Install dev dependencies
run: |
python -m pip install --upgrade pip
# remove pygfx from requirements, we install a specific commit of pygfx since both fpl and pygfx are fast evolving
python -m pip install --upgrade pip setuptools
# remove pygfx from install_requires, we install using pygfx@main
sed -i "/pygfx/d" ./setup.py
pip install git+https://github.com/pygfx/pygfx.git@main
pip install -e ".["tests"]"
Expand Down
1 change: 0 additions & 1 deletion fastplotlib/layouts/_plot.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
import traceback
import os

import ipywidgets
import pygfx
from wgpu.gui.auto import WgpuCanvas, is_jupyter

Expand Down
11 changes: 10 additions & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

install_requires = [
"numpy>=1.23.0",
"pygfx>=0.1.13",
"pygfx>=0.1.14",
]


Expand Down Expand Up @@ -43,6 +43,15 @@
"scikit-learn",
"tqdm",
"sidecar"
],

"tests-desktop":
[
"pytest",
"scipy",
"imageio",
"scikit-learn",
"tqdm",
]
}

Expand Down
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy