-
Notifications
You must be signed in to change notification settings - Fork 99
51 lines (42 loc) · 1.03 KB
/
Copy pathpython-ci.yml
File metadata and controls
51 lines (42 loc) · 1.03 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
name: Python CI
on:
push:
branches:
- main
paths-ignore:
- "**.md"
pull_request:
branches:
- main
jobs:
build:
strategy:
matrix:
os: [ubuntu-latest, windows-latest]
python: ["3.9", "3.13"]
runs-on: ${{ matrix.os }}
timeout-minutes: 10
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Install uv
uses: astral-sh/setup-uv@v6
with:
enable-cache: true
python-version: ${{ matrix.python }}
- name: Check lockfile is up to date
run: uv lock --check
- name: Install dependencies
run: uv sync --group dev
- name: Lint with ruff
if: startsWith(matrix.os, 'ubuntu')
run: |
uv run ruff check .
uv run ruff format --check .
- name: Type checking with mypy
if: startsWith(matrix.os, 'ubuntu')
run: |
uv run mypy censys
- name: Test with pytest
run: |
uv run pytest --cov --cov-fail-under=100