Skip to content

Add close_issues.yml to GitHub workflows to close issues after extended period of inactivity #5638

Add close_issues.yml to GitHub workflows to close issues after extended period of inactivity

Add close_issues.yml to GitHub workflows to close issues after extended period of inactivity #5638

Workflow file for this run

name: CI
on:
push:
pull_request:
schedule:
- cron: '0 12 1 * *' # 12:00, first day of the month
jobs:
lint:
runs-on: ubuntu-latest
env:
PYTHON: 3.9
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ env.PYTHON }}
uses: actions/setup-python@v4
with:
python-version: ${{ env.PYTHON }}
- name: Python info
run: |
which python
python --version
- name: Install system packages
run: |
sudo apt update
sudo apt install libudunits2-dev libgeos-dev libproj-dev proj-data proj-bin
- name: Install Tox
run: |
python -m pip install --upgrade pip
python -m pip install tox
- name: Check format
run: tox -e format
- name: Run linters
run: tox -e lint
docs:
runs-on: ubuntu-latest
env:
PYTHON: 3.9
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ env.PYTHON }}
uses: actions/setup-python@v4
with:
python-version: ${{ env.PYTHON }}
- name: Python info
run: |
which python
python --version
- name: Install system packages
run: |
sudo apt update
sudo apt install libudunits2-dev libgeos-dev libproj-dev proj-data proj-bin pandoc
- name: Install Tox
run: |
python -m pip install --upgrade pip
python -m pip install tox
- name: Build docs
run: tox -e docs
venv:
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
python-version: [3.9, '3.10', '3.11']
experimental: [false]
os: [ubuntu-22.04]
include:
- python-version: '3.12'
experimental: true
os: ubuntu-22.04
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Python info
run: |
which python
python --version
- name: Install system packages
run: |
sudo apt update
sudo apt install libudunits2-dev libgeos-dev libproj-dev proj-data proj-bin
- name: Cache pip and tox
uses: actions/cache@v3
if: ${{ ! matrix.experimental }}
with:
path: |
~/.cache/pip
~/.cache/srtm
.tox
key: ${{ matrix.os }}-tox-${{ matrix.python-version }}-${{ hashFiles('setup.cfg', 'pyproject.toml') }}
- name: Install Tox
run: |
python -m pip install --upgrade pip
python -m pip install tox
- name: Run test
continue-on-error: ${{ matrix.experimental }}
run: tox -e py
conda:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
python-version: [3.9, '3.10', '3.11']
experimental: [false]
defaults:
run:
shell: bash -l {0}
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: conda-incubator/setup-miniconda@v2
with:
python-version: ${{ matrix.python-version }}
activate-environment: pya
environment-file: pyaerocom_env.yml
- name: Conda info
run: |
conda --version
conda info --envs
which python
python --version
- name: Install pyaerocom
run: python -m pip install . --no-deps
- name: Run pytest
continue-on-error: ${{ matrix.experimental }}
run: pytest -ra -q --cov --no-cov-on-fail --cov-report xml
- name: Upload coverage to Codecov
if: ${{ success() }}
uses: codecov/codecov-action@v3
with:
file: ./coverage.xml
flags: unittests