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
1 change: 0 additions & 1 deletion .github/environment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ channels:
- conda-forge

dependencies:
- python==3.10
- pip
- oommf
- pytest
Expand Down
15 changes: 8 additions & 7 deletions .github/workflows/workflow.yml → .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,10 @@
name: workflow
name: tests

on:
push:
branches:
- master
pull_request:
schedule:
- cron: '0 0 * * 1' # run every Monday
workflow_dispatch:
Expand All @@ -10,11 +13,11 @@ env:
PYTEST_ADDOPTS: "--color=yes"

jobs:
workflow:
tests:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
os: [ubuntu-latest, macos-26-intel, windows-latest]
defaults:
run:
shell: bash -l {0}
Expand All @@ -24,14 +27,12 @@ jobs:
uses: actions/checkout@v2

- name: Set up conda
uses: conda-incubator/setup-miniconda@v2
uses: conda-incubator/setup-miniconda@v3
with:
python-version: 3.13
auto-update-conda: true
activate-environment: conda-environment
environment-file: .github/environment.yml
miniforge-version: latest
miniforge-variant: Mambaforge
use-mamba: true

# The first import (of discretisedfield) on Windows produces a failure in the notebook tests
# (output mismatch) because of some (hidden) message on stderr (some IO error on Windows that
Expand Down
7 changes: 3 additions & 4 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,23 +2,22 @@ exclude: 'dev'

repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v5.0.0
rev: v6.0.0
hooks:
- id: check-merge-conflict # checks for files that contain merge conflict strings
- id: check-toml # checks toml files for parseable syntax
- id: debug-statements # checks for debugger imports and py37+ `breakpoint()` calls in python source

- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.12.0
rev: v0.15.15
hooks:
# Run the linter.
- id: ruff
types_or: [python, pyi, jupyter]
args:
- --fix
- --exit-non-zero-on-fix
- --per-file-ignores
- getting-started/python-basics.ipynb:E999
exclude: getting-started/python-basics.ipynb

# Run the formatter.
- id: ruff-format
Expand Down
Loading