Skip to content
Open
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
3 changes: 0 additions & 3 deletions .darglint

This file was deleted.

10 changes: 0 additions & 10 deletions .flake8

This file was deleted.

5 changes: 4 additions & 1 deletion .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,12 @@ tick all *appropriate* boxes. But please read our
[contribution guide](https://github.com/robbievanleeuwen/plane-stress/blob/master/CONTRIBUTING.md)
at least once, it will save you unnecessary review cycles! -->

- [ ] Added a description of your pull request below.
- [ ] Added **tests** for changed code.
- [ ] Updated **documentation** for changed code.
- [ ] Run the **Nox** test suite to check for errors and warnings.
- [ ] Run `uv run pre-commit run --all-files` and `uv run pyright` to ensure code quality.

<!-- If you have *any* questions to *any* of the points above, just **submit and ask**!
This checklist is here to *help* you, not to deter you from contributing! -->

<!-- PR descrtiption below -->
24 changes: 0 additions & 24 deletions .github/dependabot.yml

This file was deleted.

11 changes: 6 additions & 5 deletions .github/release-drafter.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,8 @@ categories:
- "build"

category-template: "### $TITLE"
name-template: "v$RESOLVED_VERSION"
tag-template: "v$RESOLVED_VERSION"

version-resolver:
major:
Expand All @@ -48,14 +50,13 @@ version-resolver:
- "patch"
default: patch

exclude-contributors:
- "robbievanleeuwen"

# Custom text at start of release
# header: |
# xxx
header: >

This release...

template: |

## What's Changed

$CHANGES
Expand Down
195 changes: 195 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,195 @@
name: CI

on:
push:
branches:
- master
pull_request:
types: [opened, reopened, synchronize]

env:
UV_VERSION: 0.6.17

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

jobs:
pre-commit:
name: pre-commit
runs-on: ubuntu-latest

steps:
- name: Check out the repo
uses: actions/checkout@v4

- name: Install uv version ${{ env.UV_VERSION }}
uses: astral-sh/setup-uv@v6
with:
version: ${{ env.UV_VERSION }}
enable-cache: true

- name: Install python using uv
run: uv python install

- name: Install dependencies
run: uv sync --locked --only-group lint

- name: Run pre-commit
run: uv run --no-sync pre-commit run --all-files --color always --show-diff-on-failure

type-checking:
name: type-checking
runs-on: ubuntu-latest

steps:
- name: Check out the repo
uses: actions/checkout@v4

- name: Install uv version ${{ env.UV_VERSION }}
uses: astral-sh/setup-uv@v6
with:
version: ${{ env.UV_VERSION }}
enable-cache: true

- name: Install python using uv
run: uv python install

- name: Install dependencies
run: uv sync --locked --only-group lint

- name: Run pyright
run: uv run --no-sync pyright

tests:
name: ${{ matrix.session }} ${{ matrix.python }} [${{ matrix.os }}]
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
include:
- {python: '3.13', os: ubuntu-latest, session: tests}
- {python: '3.12', os: ubuntu-latest, session: tests}
- {python: '3.11', os: ubuntu-latest, session: tests}
- {python: '3.13', os: windows-latest, session: tests}
- {python: '3.12', os: windows-latest, session: tests}
- {python: '3.11', os: windows-latest, session: tests}
- {python: '3.13', os: macos-latest, session: tests}
- {python: '3.12', os: macos-latest, session: tests}
- {python: '3.11', os: macos-latest, session: tests}
- {python: '3.13', os: macos-13, session: tests}
- {python: '3.12', os: macos-13, session: tests}
- {python: '3.11', os: macos-13, session: tests}

steps:
- name: Check out the repo
uses: actions/checkout@v4

- name: Install uv version ${{ env.UV_VERSION }} and set python to version ${{ matrix.python }}
uses: astral-sh/setup-uv@v6
with:
version: ${{ env.UV_VERSION }}
python-version: ${{ matrix.python }}
enable-cache: true

- name: Install python using uv
run: uv python install

- name: Install test dependencies (mac & windows)
if: matrix.os != 'ubuntu-latest'
run: uv sync --locked --no-default-groups --group test

- name: Install test dependencies (linux)
if: matrix.os == 'ubuntu-latest'
run: uv sync --locked --no-default-groups --group test --no-install-package gmsh

- name: Install gmsh-nox (linux)
if: matrix.os == 'ubuntu-latest'
run: uv pip install --index https://gmsh.info/python-packages-dev-nox 'gmsh<4.13.2'

- name: Run pytest
run: uv run --no-sync coverage run --parallel-mode -m pytest -m 'not benchmark_suite'

- name: Upload coverage data
uses: actions/upload-artifact@v4
with:
name: coverage-data-${{ matrix.session }}-${{ matrix.os }}-${{ matrix.python
}}
include-hidden-files: true
path: .coverage.*

docs-build:
name: docs-build
runs-on: ubuntu-latest

steps:
- name: Check out the repo
uses: actions/checkout@v4

- name: Install uv version ${{ env.UV_VERSION }}
uses: astral-sh/setup-uv@v6
with:
version: ${{ env.UV_VERSION }}
enable-cache: true

- name: Install python using uv
run: uv python install

- name: Install dependencies
run: uv sync --locked --no-default-groups --group docs --no-install-package gmsh

- name: Install gmsh-nox
run: uv pip install --index https://gmsh.info/python-packages-dev-nox 'gmsh<4.13.2'

- name: Install pandoc
uses: pandoc/actions/setup@v1

- name: Build docs
run: uv run --no-sync sphinx-build --color docs docs/_build

- name: Upload docs
uses: actions/upload-artifact@v4
with:
name: docs
path: docs/_build

coverage:
name: coverage
runs-on: ubuntu-latest
needs: tests

steps:
- name: Check out the repo
uses: actions/checkout@v4

- name: Install uv version ${{ env.UV_VERSION }}
uses: astral-sh/setup-uv@v6
with:
version: ${{ env.UV_VERSION }}
enable-cache: true

- name: Install python using uv
run: uv python install

- name: Install dependencies
run: uv sync --locked --only-group test

- name: Download coverage data
uses: actions/download-artifact@v4
with:
pattern: coverage-data-*
merge-multiple: true

- name: Combine coverage data
run: uv run --no-sync coverage combine

- name: Display coverage report
run: uv run --no-sync coverage report -i

- name: Create coverage report
run: uv run --no-sync coverage xml -i

- name: Upload coverage report
uses: codecov/codecov-action@v5
with:
token: ${{ secrets.CODECOV_TOKEN }}
5 changes: 0 additions & 5 deletions .github/workflows/constraints.txt

This file was deleted.

12 changes: 7 additions & 5 deletions .github/workflows/greetings.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,10 @@ jobs:
issues: write
pull-requests: write
steps:
- uses: actions/first-interaction@v1
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
issue-message: "Thanks for opening your first issue in ``planestress`` :raised_hands: Pull requests are always welcome :wink:"
pr-message: "Thank you for your contribution to ``planestress`` :pray: We will be reviewing your PR shortly :monocle_face:"
- uses: actions/first-interaction@v1
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
issue-message: 'Thanks for opening your first issue in ``planestress``
:raised_hands: Pull requests are always welcome :wink:'
pr-message: 'Thank you for your contribution to ``planestress`` :pray:
We will be reviewing your PR shortly :monocle_face:'
14 changes: 7 additions & 7 deletions .github/workflows/labeler.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,16 +3,16 @@ name: Labeler
on:
push:
branches:
- master
- master

jobs:
labeler:
runs-on: ubuntu-latest
steps:
- name: Check out the repository
uses: actions/checkout@v4
- name: Check out the repository
uses: actions/checkout@v4

- name: Run Labeler
uses: crazy-max/ghaction-github-labeler@v5.0.0
with:
skip-delete: true
- name: Run Labeler
uses: crazy-max/ghaction-github-labeler@v5
with:
skip-delete: true
Loading
Loading