fix: global code update #558
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: build | |
on: | |
workflow_dispatch: | |
push: | |
branches: | |
- main | |
pull_request: | |
branches: | |
- main | |
types: | |
- opened | |
- edited | |
- synchronize | |
jobs: | |
lint: | |
runs-on: ubuntu-24.04 | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Setup Python | |
uses: actions/setup-python@v5 | |
with: | |
python-version: '3.13.2' | |
cache-dependency-path: 'requirements-dev.txt' | |
- name: Install uv | |
uses: astral-sh/setup-uv@v5 | |
with: | |
enable-cache: true | |
cache-dependency-glob: 'requirements**.txt' | |
- name: Install Python dependencies | |
run: make install-dev DC_ENV=ci | |
- name: Run lint checks | |
run: make lint | |
test: | |
runs-on: ubuntu-24.04 | |
needs: lint | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Update and install Linux packages | |
run: | | |
sudo add-apt-repository ppa:ubuntugis/ubuntugis-unstable | |
sudo apt-get update | |
sudo apt-get install libgdal-dev gdal-bin python3-gdal | |
- name: Setup Python | |
uses: actions/setup-python@v5 | |
with: | |
python-version: '3.13.2' | |
cache-dependency-path: | | |
'requirements.txt' | |
'requirements-dev.txt' | |
- name: Install uv | |
uses: astral-sh/setup-uv@v5 | |
with: | |
enable-cache: true | |
cache-dependency-glob: 'requirements**.txt' | |
- name: Install Python dependencies | |
run: | | |
make install DC_ENV=ci | |
make install-dev DC_ENV=ci | |
- name: Restore data cache | |
uses: actions/cache@v4 | |
with: | |
path: Data/ | |
key: ${{ runner.os }}-data-${{ hashFiles('Data/*') }} | |
restore-keys: ${{ runner.os }}-data- | |
- name: Download data | |
if: ${{ hashFiles('Data/*') == '' }} | |
run: make download-soil-data | |
- name: Run tests | |
run: make test |