@@ -11,105 +11,81 @@ jobs:
1111 name : Lint
1212 runs-on : ubuntu-latest
1313 steps :
14- - uses : actions/checkout@a5ac7e51b41094c92402da3b24376905380afc29 # v4.1.6
15- - uses : actions/setup-node@60ecd5dd1b667a8e52112f999ebc6e0c8267832c # v4.0.2
14+ - uses : actions/checkout@v4
15+ - uses : actions/setup-node@v4
1616 with :
17- node-version : 20
18- - uses : actions/cache@0c45773b623bea8c8e75f6c82b208c3cf94ea4f9 # v4.0.2
19- with :
20- path : node_modules
21- key : node-modules-${{ hashFiles('package-lock.json') }}
22- restore-keys : node-modules-
23- - run : npm ci
17+ node-version : 22
18+ cache : npm
19+ - run : npm install
2420 - run : npm run lint
2521
2622 type-check :
2723 name : Type Check
2824 runs-on : ubuntu-latest
2925 needs : lint
3026 steps :
31- - uses : actions/checkout@a5ac7e51b41094c92402da3b24376905380afc29 # v4.1.6
32- - uses : actions/setup-node@60ecd5dd1b667a8e52112f999ebc6e0c8267832c # v4.0.2
33- with :
34- node-version : 20
35- - uses : actions/cache@0c45773b623bea8c8e75f6c82b208c3cf94ea4f9 # v4.0.2
27+ - uses : actions/checkout@v4
28+ - uses : actions/setup-node@v4
3629 with :
37- path : node_modules
38- key : node-modules-${{ hashFiles('package-lock.json') }}
39- restore-keys : node-modules-
40- - run : npm ci
30+ node-version : 22
31+ cache : npm
32+ - run : npm install
4133 - run : npx tsc --noEmit
4234
4335 test-frontend :
4436 name : Test Frontend
4537 runs-on : ubuntu-latest
4638 needs : lint
4739 steps :
48- - uses : actions/checkout@a5ac7e51b41094c92402da3b24376905380afc29 # v4.1.6
49- - uses : actions/setup-node@60ecd5dd1b667a8e52112f999ebc6e0c8267832c # v4.0.2
40+ - uses : actions/checkout@v4
41+ - uses : actions/setup-node@v4
5042 with :
51- node-version : 20
52- - uses : actions/cache@0c45773b623bea8c8e75f6c82b208c3cf94ea4f9 # v4.0.2
53- with :
54- path : node_modules
55- key : node-modules-${{ hashFiles('package-lock.json') }}
56- restore-keys : node-modules-
57- - run : npm ci
43+ node-version : 22
44+ cache : npm
45+ - run : npm install
5846 - run : npm run build --workspace=src/frontend
5947
6048 test-backend :
6149 name : Test Backend
6250 runs-on : ubuntu-latest
6351 needs : lint
6452 steps :
65- - uses : actions/checkout@a5ac7e51b41094c92402da3b24376905380afc29 # v4.1.6
66- - uses : actions/setup-node@60ecd5dd1b667a8e52112f999ebc6e0c8267832c # v4.0.2
67- with :
68- node-version : 20
69- - uses : actions/cache@0c45773b623bea8c8e75f6c82b208c3cf94ea4f9 # v4.0.2
53+ - uses : actions/checkout@v4
54+ - uses : actions/setup-node@v4
7055 with :
71- path : node_modules
72- key : node-modules-${{ hashFiles('package-lock.json') }}
73- restore-keys : node-modules-
74- - run : npm ci
56+ node-version : 22
57+ cache : npm
58+ - run : npm install
7559 - run : npm run test --workspace=src/backend
7660
7761 test-ml :
7862 name : Test ML Pipeline
7963 runs-on : ubuntu-latest
8064 needs : lint
8165 steps :
82- - uses : actions/checkout@a5ac7e51b41094c92402da3b24376905380afc29 # v4.1.6
83- - uses : actions/setup-python@82c7e631bb3cdc910f68e0081d67478d79c6982d # v5.1.0
66+ - uses : actions/checkout@v4
67+ - uses : actions/setup-python@v5
8468 with :
8569 python-version : ' 3.11'
86- - uses : actions/cache@0c45773b623bea8c8e75f6c82b208c3cf94ea4f9 # v4.0.2
87- with :
88- path : ~/.cache/pip
89- key : pip-${{ hashFiles('requirements.txt') }}
90- restore-keys : pip-
70+ cache : pip
9171 - run : pip install -r requirements.txt
92- - run : python -m pytest src/ml/ --tb=short -q --cov=src/ml --cov-report=xml --cov-fail-under=70
72+ - run : python -m pytest tests/ --tb=short -q --cov=src/ml --cov-report=xml
9373 - run : python -m flake8 src/ml/ --max-line-length=120
94- - run : python -m mypy src/ml/ --ignore-missing-imports
74+ - run : python -m mypy src/ml/ --ignore-missing-imports --explicit-package-bases
9575
9676 security :
9777 name : Security Scanning
9878 runs-on : ubuntu-latest
9979 steps :
100- - uses : actions/checkout@a5ac7e51b41094c92402da3b24376905380afc29 # v4.1.6
101- - uses : actions/setup-node@60ecd5dd1b667a8e52112f999ebc6e0c8267832c # v4.0.2
80+ - uses : actions/checkout@v4
81+ - uses : actions/setup-node@v4
10282 with :
103- node-version : 20
104- - uses : actions/setup-python@82c7e631bb3cdc910f68e0081d67478d79c6982d # v5.1.0
83+ node-version : 22
84+ cache : npm
85+ - uses : actions/setup-python@v5
10586 with :
10687 python-version : ' 3.11'
107- - uses : actions/cache@0c45773b623bea8c8e75f6c82b208c3cf94ea4f9 # v4.0.2
108- with :
109- path : node_modules
110- key : node-modules-${{ hashFiles('package-lock.json') }}
111- restore-keys : node-modules-
112- - run : npm ci
88+ - run : npm install
11389 - run : npm audit --audit-level=high --omit=dev
11490 - run : pip install pip-audit
11591 - run : pip-audit -r requirements.txt
@@ -119,14 +95,10 @@ jobs:
11995 runs-on : ubuntu-latest
12096 needs : [test-frontend, test-backend, test-ml, type-check, security]
12197 steps :
122- - uses : actions/checkout@a5ac7e51b41094c92402da3b24376905380afc29 # v4.1.6
123- - uses : actions/setup-node@60ecd5dd1b667a8e52112f999ebc6e0c8267832c # v4.0.2
124- with :
125- node-version : 20
126- - uses : actions/cache@0c45773b623bea8c8e75f6c82b208c3cf94ea4f9 # v4.0.2
98+ - uses : actions/checkout@v4
99+ - uses : actions/setup-node@v4
127100 with :
128- path : node_modules
129- key : node-modules-${{ hashFiles('package-lock.json') }}
130- restore-keys : node-modules-
131- - run : npm ci
101+ node-version : 22
102+ cache : npm
103+ - run : npm install
132104 - run : npm run build
0 commit comments