Skip to content

Bump actions/checkout from 3 to 4 #215

Bump actions/checkout from 3 to 4

Bump actions/checkout from 3 to 4 #215

Workflow file for this run

name: CI
on:
push:
branches: [ trunk ]
pull_request:
branches: [ trunk ]
jobs:
lint:
runs-on: ubuntu-20.04
timeout-minutes: 5
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v4
with:
python-version: '3.8'
- uses: actions/cache@v3
with:
path: ~/.cache/pip
key:
${{ runner.os }}-pip-lint-${{ hashFiles('pyproject.toml', 'setup.py', 'tox.ini') }}
restore-keys: |
${{ runner.os }}-pip-lint-
${{ runner.os }}-pip-
- run: python -m pip install 'tox<4'
- run: tox -q -p all -e flake8,towncrier,twine,check-manifest
docs:
runs-on: ubuntu-20.04
timeout-minutes: 5
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v4
with:
python-version: "3.8"
- uses: actions/cache@v3
with:
path: ~/.cache/pip
key:
${{ runner.os }}-pip-docs-${{ hashFiles('pyproject.toml', 'setup.py', 'tox.ini') }}
restore-keys: |
${{ runner.os }}-pip-docs-
${{ runner.os }}-pip-
- run: python -m pip install tox
- run: tox -q -e docs
test:
name: "Test ${{ matrix.python-version }} with ${{ matrix.twisted-version }} Twisted"
runs-on: ubuntu-20.04
timeout-minutes: 10
continue-on-error: ${{ matrix.experimental }}
strategy:
matrix:
python-version: ["3.7", "3.8", "3.9", "3.10", "pypy-3.8", "pypy-3.9"]
twisted-version: ["lowest", "latest"]
experimental: [false]
include:
- python-version: "3.8"
twisted-version: "trunk"
experimental: true
- python-version: "3.9"
twisted-version: "trunk"
experimental: true
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- uses: actions/cache@v3
with:
path: ~/.cache/pip
key:
${{ runner.os }}-pip-${{ matrix.python-version }}-${{ hashFiles('pyproject.toml', 'setup.py', 'tox.ini') }}
restore-keys: |
${{ runner.os }}-pip-${{ matrix.python-version }}-
${{ runner.os }}-pip-
- name: Translate Python version to Tox factor
id: pyfactor
shell: python
run: |
table = {
"3.7": "py37",
"3.8": "py38",
"3.9": "py39",
"3.10": "py310",
"pypy-3.8": "pypy3",
"pypy-3.9": "pypy3",
}
factor = table["${{ matrix.python-version }}"]
print("::set-output name=value::" + factor)
- run: python -m pip install tox coveralls
- run: tox -e ${{ steps.pyfactor.outputs.value }}-twisted_${{ matrix.twisted-version }}
- run: coveralls
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
COVERALLS_REPO_TOKEN: 4nctuKHTnVtbdmty2FgdO3iiWm1nb7xc4
COVERALLS_FLAG_NAME: python_${{ matrix.python-version }}-twisted_${{ matrix.twisted-version }}
COVERALLS_PARALLEL: true