Skip to content

add mypy to ci (but ignore for now), add numpy typing plugin #78

add mypy to ci (but ignore for now), add numpy typing plugin

add mypy to ci (but ignore for now), add numpy typing plugin #78

Workflow file for this run

name: CI
on:
push:
paths-ignore:
- '**.md'
- '.gitignore'
pull_request:
branches:
- main
- develop
paths-ignore:
- '**.md'
- '.gitignore'
jobs:
check:
name: Check
runs-on: ubuntu-latest
steps:
- name: Checkout repo
uses: actions/checkout@v4
- name: Setup Python
uses: actions/setup-python@v5
with:
python-version: 3.9
cache: 'pip'
cache-dependency-path: pyproject.toml
- name: Install Python packages
run: pip install ".[lint]"
- name: Linter
run: ruff check .
- name: Formatter
run: ruff format --check
# TODO: enable when passing
# - name: Type checker
# run: mypy flopy4
build:
name: Build
runs-on: ubuntu-latest
steps:
- name: Checkout repo
uses: actions/checkout@v3
- name: Setup Python
uses: actions/setup-python@v5
with:
python-version: 3.9
- name: Install Python packages
run: |
pip install --upgrade pip
pip install build twine
pip --verbose install .
- name: Print package version
run: python -c "from flopy4 import version; print(version.__version__)"
- name: Build package
run: python -m build
test:
name: Test
needs:
- build
- lint

Check failure on line 72 in .github/workflows/ci.yml

View workflow run for this annotation

GitHub Actions / CI

Invalid workflow file

The workflow is not valid. .github/workflows/ci.yml (Line: 72, Col: 9): Job 'test' depends on unknown job 'lint'.
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ ubuntu-22.04, macos-12, windows-2022 ]
python: [ 3.9, "3.10", "3.11", "3.12" ]
env:
GCC_V: 11
steps:
- name: Checkout repo
uses: actions/checkout@v4
- name: Install nightly build
uses: modflowpy/install-modflow-action@v1
with:
repo: modflow6-nightly-build
- name: Setup Python
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python }}
- name: Install Python packages
run: pip install ".[test]"
- name: Run tests
run: pytest -v -n auto