Skip to content

[AUTOMATED] Update version number #2104

[AUTOMATED] Update version number

[AUTOMATED] Update version number #2104

Workflow file for this run

name: Test and build
on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
schedule:
- cron: "0 7 * * 1"
permissions: {}
concurrency:
group: test-and-build-${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
style-checks:
name: Run style checks
runs-on: ubuntu-22.04
steps:
- name: Set up Python
uses: actions/setup-python@5fda3b95a4ea91299a34e894583c3862153e4b97 # v7.0.0
with:
python-version: "3.14"
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
persist-credentials: false
- run: |
python3 -m pip install .[style]
name: Install defelement
- run: |
python3 -m ruff format --check .
python3 -m ruff check .
name: Ruff checks
- run: |
python3 -m pydocstyle .
name: Pydocstyle checks
- run: |
python3 -m mypy --install-types --non-interactive .
python3 -m mypy .
name: mypy checks
test-build-website:
name: Test building of defelement
runs-on: ubuntu-22.04
steps:
- name: Set up Python
uses: actions/setup-python@5fda3b95a4ea91299a34e894583c3862153e4b97 # v7.0.0
with:
python-version: "3.14"
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
persist-credentials: false
- name: Clone Symfem
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
path: ./symfem
repository: mscroggs/symfem
ref: main
persist-credentials: false
- name: Install Symfem
run: |
cd symfem
python3 -m pip install .[optional]
- name: Clone verification
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
path: ./verification
repository: DefElement/DefElement
ref: verification
persist-credentials: false
continue-on-error: true
- run: mkdir -p ~/.local/share/fonts
name: Make font folder
- name: Clone Varela Round
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
path: ./varela-r
repository: avrahamcornfeld/Varela-Round-Hebrew
ref: master
persist-credentials: false
- run: cp varela-r/fonts/VarelaRound-Regular.otf ~/.local/share/fonts/
name: Install Varela Round
- name: Download and install Computer Modern
run: |
wget https://downloads.sourceforge.net/project/cm-unicode/cm-unicode/0.7.0/cm-unicode-0.7.0-otf.tar.xz
tar -xf cm-unicode-0.7.0-otf.tar.xz
cp cm-unicode-0.7.0/cmunti.otf ~/.local/share/fonts/
- run: python3 -m pip install .
name: Install defelement
- run: python3 build.py _test_html --no-cache --verification-json verification/verification.json --test auto --processes 4 --include-simplefem
name: Build website HTML
permissions:
contents: read
build-website:
name: Build and deploy website
needs:
- test-build-website
- run-tests
uses: $/.github/workflows/build.yml
permissions:
contents: read
pages: write # Allow updating of website
id-token: write # Needed by pages
verification:
name: Test verification
runs-on: ubuntu-22.04
steps:
- name: Set up Python
uses: actions/setup-python@5fda3b95a4ea91299a34e894583c3862153e4b97 # v7.0.0
with:
python-version: "3.14"
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
persist-credentials: false
- name: Load Symfem cache
uses: actions/cache/restore@55cc8345863c7cc4c66a329aec7e433d2d1c52a9 # v6.1.0
with:
path: /home/runner/.cache/symfem
key: symfem-cache
- name: Clone Symfem
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
path: ./symfem
repository: mscroggs/symfem
ref: main
persist-credentials: false
- name: Install Symfem
run: |
cd symfem
python3 -m pip install .[optional]
- run: python3 -m pip install .
name: Install defelement
- name: Install Julia
uses: julia-actions/setup-julia@fa02766e078afaaf09b14210362cee14137e6a32 # v3.0.2
with:
# juliacall only supports Julia < 1.12 for now
version: "1.11"
- name: Install implementations
run: |
python3 -m pip install setuptools juliacall
python3 install_implementations.py --install-type verification
- run: python3 verify.py --fail-on-missing-libraries --impl simplefem --assert-passing --print-reasons
name: Check that simplefem verification passes
- run: python3 verify.py verification-serial.json --test auto --fail-on-missing-libraries
name: Run verification test in serial
- run: python3 verify.py verification-4.json --test auto --processes 4 --fail-on-missing-libraries
name: Run verification test on 4 processes
- name: Check that two verifications runs give the same results
run: python3 .github/scripts/compare_json.py verification-serial.json verification-4.json
permissions:
contents: read
run-tests:
name: Run tests
runs-on: ubuntu-22.04
steps:
- name: Set up Python
uses: actions/setup-python@5fda3b95a4ea91299a34e894583c3862153e4b97 # v7.0.0
with:
python-version: "3.14"
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
persist-credentials: false
- run: python3 -m pip install pytest-xdist
name: Install dependencies
- name: Load Symfem cache
uses: actions/cache/restore@55cc8345863c7cc4c66a329aec7e433d2d1c52a9 # v6.1.0
with:
path: /home/runner/.cache/symfem
key: symfem-cache
- name: Clone Symfem
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
path: ./symfem
repository: mscroggs/symfem
ref: main
persist-credentials: false
- name: Install Symfem
run: |
cd symfem
python3 -m pip install .[optional]
- run: python3 -m pip install .
name: Install defelement
- name: Install implementations
run: python3 install_implementations.py --install-type all
- name: Install LaTeΧ
run: |
sudo apt-get update
sudo apt-get install -y texlive-latex-base
- run: python3 -m pytest -n4 test
name: Run tests with pytest
permissions:
contents: read