Skip to content

Commit 14534b7

Browse files
committed
ci: fix YAML and relax mypy on tools
1 parent 07aead3 commit 14534b7

1 file changed

Lines changed: 11 additions & 18 deletions

File tree

.github/workflows/ci.yml

Lines changed: 11 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@ jobs:
1010
runs-on: ubuntu-latest
1111
steps:
1212
- uses: actions/checkout@v4
13-
1413
- uses: actions/setup-python@v5
1514
with:
1615
python-version: "3.11"
@@ -23,41 +22,35 @@ jobs:
2322
- name: Run Ruff
2423
run: ruff check .
2524

26-
- name: Run Black
25+
- name: Run Black (check only)
2726
run: black --check .
2827

29-
- name: Run MyPy
30-
- run: mypy --install-types --non-interactive --ignore-missing-imports --disable-error-code no-untyped-def tools
31-
28+
- name: Run MyPy on tools
29+
run: >
30+
mypy --install-types --non-interactive
31+
--ignore-missing-imports
32+
--disable-error-code no-untyped-def
33+
tools
3234
3335
build-artifacts:
3436
needs: qa
3537
runs-on: ubuntu-latest
3638
steps:
3739
- uses: actions/checkout@v4
38-
3940
- uses: actions/setup-python@v5
4041
with:
4142
python-version: "3.11"
4243

43-
# Création d’un CSV factice si le vrai est ignoré par .gitignore
44-
- name: Ensure risk_matrix.csv exists
45-
run: |
46-
if [ ! -f "02-Matrices/risk_matrix.csv" ]; then
47-
mkdir -p 02-Matrices
48-
echo "ID,Asset,Threat,Vulnerability,Probability,Impact,Risk,Decision,Recommendation" > 02-Matrices/risk_matrix.csv
49-
echo "R001,Example asset,Example threat,Example vulnerability,1,1,1,Accept,Example recommendation" >> 02-Matrices/risk_matrix.csv
50-
fi
51-
52-
- name: Install Python deps
44+
- name: Install build dependencies
5345
run: |
5446
python -m pip install -U pip
5547
pip install pandas openpyxl
5648
57-
- name: Generate XLSX
49+
- name: Generate Excel risk matrix
5850
run: python tools/csv2xlsx.py
5951

60-
- uses: actions/upload-artifact@v4
52+
- name: Upload risk matrix artifact
53+
uses: actions/upload-artifact@v4
6154
with:
6255
name: risk-matrix-xlsx
6356
path: docs/reports/risk_matrix.xlsx

0 commit comments

Comments
 (0)