Skip to content

🐛 Save streamlit rand quarto reports with Posix and change str paths to Path #192

🐛 Save streamlit rand quarto reports with Posix and change str paths to Path

🐛 Save streamlit rand quarto reports with Posix and change str paths to Path #192

Workflow file for this run

name: Python package
on:
push:
branches: [main]
pull_request:
branches: [main]
release:
types: [published]
jobs:
test:
name: Unittests+streamlit
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.9", "3.10", "3.11", "3.12", "3.13"]
steps:
- uses: actions/checkout@v4
- uses: psf/black@stable
- uses: isort/isort-action@v1
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
cache: 'pip' # caching pip dependencies
cache-dependency-path: '**/pyproject.toml'
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install pytest
pip install -e .
- name: Run tests
run: python -m pytest tests
- name: Execute streamlit report
run: |
cd docs
vuegen --directory example_data/Earth_microbiome_vuegen_demo_notebook
vuegen --config example_data/Earth_microbiome_vuegen_demo_notebook/Earth_microbiome_vuegen_demo_notebook_config.yaml
other-reports:
name: Integration tests
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.9", "3.10", "3.11", "3.12", "3.13"]
steps:
- uses: actions/checkout@v4
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
cache: 'pip' # caching pip dependencies
cache-dependency-path: '**/pyproject.toml'
- name: Install dependencies
run: |
pip install --upgrade pip
pip install -e "."
- name: Execute streamlit report (to check)
run: |
cd docs
vuegen -dir example_data/Earth_microbiome_vuegen_demo_notebook
vuegen -c example_data/Earth_microbiome_vuegen_demo_notebook/Earth_microbiome_vuegen_demo_notebook_config.yaml
# repeat for easier inspection on GitHub:
- name: quarto html report
run: |
cd docs
vuegen -dir example_data/Earth_microbiome_vuegen_demo_notebook -rt html
vuegen -c example_data/Earth_microbiome_vuegen_demo_notebook/Earth_microbiome_vuegen_demo_notebook_config.yaml -rt html
- name: quarto pdf report
run: |
cd docs
vuegen -dir example_data/Earth_microbiome_vuegen_demo_notebook -rt pdf
vuegen -c example_data/Earth_microbiome_vuegen_demo_notebook/Earth_microbiome_vuegen_demo_notebook_config.yaml -rt pdf
- name: quarto docx report
run: |
cd docs
vuegen -dir example_data/Earth_microbiome_vuegen_demo_notebook -rt docx
vuegen -c example_data/Earth_microbiome_vuegen_demo_notebook/Earth_microbiome_vuegen_demo_notebook_config.yaml -rt docx
- name: quarto odt report
run: |
cd docs
vuegen -dir example_data/Earth_microbiome_vuegen_demo_notebook -rt odt
vuegen -c example_data/Earth_microbiome_vuegen_demo_notebook/Earth_microbiome_vuegen_demo_notebook_config.yaml -rt odt
- name: quarto revealjs report
run: |
cd docs
vuegen -dir example_data/Earth_microbiome_vuegen_demo_notebook -rt revealjs
vuegen -c example_data/Earth_microbiome_vuegen_demo_notebook/Earth_microbiome_vuegen_demo_notebook_config.yaml -rt revealjs
- name: quarto pptx report
run: |
cd docs
vuegen -dir example_data/Earth_microbiome_vuegen_demo_notebook -rt pptx
vuegen -c example_data/Earth_microbiome_vuegen_demo_notebook/Earth_microbiome_vuegen_demo_notebook_config.yaml -rt pptx
- name: quarto jupyter report
run: |
cd docs
vuegen -dir example_data/Earth_microbiome_vuegen_demo_notebook -rt jupyter
vuegen -c example_data/Earth_microbiome_vuegen_demo_notebook/Earth_microbiome_vuegen_demo_notebook_config.yaml -rt jupyter
publish:
name: Publish package to PyPI
if: startsWith(github.ref, 'refs/tags')
permissions:
id-token: write
needs:
- test
- other-reports
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: "3.11"
- name: Install twine and build
run: python -m pip install --upgrade twine build
- name: Build
run: python -m build
- name: Publish package distributions to PyPI
uses: pypa/gh-action-pypi-publish@release/v1