mirror of
https://github.com/grafana/grafana.git
synced 2024-12-24 16:10:22 -06:00
Chore: Enable strict Typescript checks (#41198)
* Chore: Enable strict Typescript checking * Chore: Remove old strict budget checks
This commit is contained in:
parent
eb223a6645
commit
14ddb2939c
10
.drone.yml
10
.drone.yml
@ -68,7 +68,6 @@ steps:
|
|||||||
- yarn run prettier:check
|
- yarn run prettier:check
|
||||||
- yarn run lint
|
- yarn run lint
|
||||||
- yarn run typecheck
|
- yarn run typecheck
|
||||||
- yarn run check-strict
|
|
||||||
depends_on:
|
depends_on:
|
||||||
- initialize
|
- initialize
|
||||||
environment:
|
environment:
|
||||||
@ -340,7 +339,6 @@ steps:
|
|||||||
- yarn run prettier:check
|
- yarn run prettier:check
|
||||||
- yarn run lint
|
- yarn run lint
|
||||||
- yarn run typecheck
|
- yarn run typecheck
|
||||||
- yarn run check-strict
|
|
||||||
depends_on:
|
depends_on:
|
||||||
- initialize
|
- initialize
|
||||||
environment:
|
environment:
|
||||||
@ -793,7 +791,6 @@ steps:
|
|||||||
- yarn run prettier:check
|
- yarn run prettier:check
|
||||||
- yarn run lint
|
- yarn run lint
|
||||||
- yarn run typecheck
|
- yarn run typecheck
|
||||||
- yarn run check-strict
|
|
||||||
depends_on:
|
depends_on:
|
||||||
- initialize
|
- initialize
|
||||||
environment:
|
environment:
|
||||||
@ -1171,7 +1168,6 @@ steps:
|
|||||||
- yarn run prettier:check
|
- yarn run prettier:check
|
||||||
- yarn run lint
|
- yarn run lint
|
||||||
- yarn run typecheck
|
- yarn run typecheck
|
||||||
- yarn run check-strict
|
|
||||||
depends_on:
|
depends_on:
|
||||||
- initialize
|
- initialize
|
||||||
environment:
|
environment:
|
||||||
@ -1727,7 +1723,6 @@ steps:
|
|||||||
- yarn run prettier:check
|
- yarn run prettier:check
|
||||||
- yarn run lint
|
- yarn run lint
|
||||||
- yarn run typecheck
|
- yarn run typecheck
|
||||||
- yarn run check-strict
|
|
||||||
depends_on:
|
depends_on:
|
||||||
- initialize
|
- initialize
|
||||||
environment:
|
environment:
|
||||||
@ -2094,7 +2089,6 @@ steps:
|
|||||||
- yarn run prettier:check
|
- yarn run prettier:check
|
||||||
- yarn run lint
|
- yarn run lint
|
||||||
- yarn run typecheck
|
- yarn run typecheck
|
||||||
- yarn run check-strict
|
|
||||||
depends_on:
|
depends_on:
|
||||||
- initialize
|
- initialize
|
||||||
environment:
|
environment:
|
||||||
@ -2647,7 +2641,6 @@ steps:
|
|||||||
- yarn run prettier:check
|
- yarn run prettier:check
|
||||||
- yarn run lint
|
- yarn run lint
|
||||||
- yarn run typecheck
|
- yarn run typecheck
|
||||||
- yarn run check-strict
|
|
||||||
depends_on:
|
depends_on:
|
||||||
- initialize
|
- initialize
|
||||||
environment:
|
environment:
|
||||||
@ -2986,7 +2979,6 @@ steps:
|
|||||||
- yarn run prettier:check
|
- yarn run prettier:check
|
||||||
- yarn run lint
|
- yarn run lint
|
||||||
- yarn run typecheck
|
- yarn run typecheck
|
||||||
- yarn run check-strict
|
|
||||||
depends_on:
|
depends_on:
|
||||||
- initialize
|
- initialize
|
||||||
environment:
|
environment:
|
||||||
@ -3449,6 +3441,6 @@ kind: secret
|
|||||||
name: drone_token
|
name: drone_token
|
||||||
---
|
---
|
||||||
kind: signature
|
kind: signature
|
||||||
hmac: 0fc151dbfb52c9055ebe8b2c8393d351bed186b1c52a1ca61e67a58c1e7fce52
|
hmac: 746a9f310520cd57b0a464b91049565aa99138fbec92568cadd99d51871e8e56
|
||||||
|
|
||||||
...
|
...
|
||||||
|
@ -8,7 +8,6 @@
|
|||||||
"scripts": {
|
"scripts": {
|
||||||
"api-tests": "jest --notify --watch --config=devenv/e2e-api-tests/jest.js",
|
"api-tests": "jest --notify --watch --config=devenv/e2e-api-tests/jest.js",
|
||||||
"build": "webpack --config scripts/webpack/webpack.prod.js",
|
"build": "webpack --config scripts/webpack/webpack.prod.js",
|
||||||
"check-strict": "./scripts/ci-check-strict.sh",
|
|
||||||
"dev": "webpack --progress --color --config scripts/webpack/webpack.dev.js",
|
"dev": "webpack --progress --color --config scripts/webpack/webpack.dev.js",
|
||||||
"e2e": "./e2e/start-and-run-suite",
|
"e2e": "./e2e/start-and-run-suite",
|
||||||
"e2e:debug": "./e2e/start-and-run-suite debug",
|
"e2e:debug": "./e2e/start-and-run-suite debug",
|
||||||
|
@ -1,13 +0,0 @@
|
|||||||
#!/bin/bash
|
|
||||||
set -e
|
|
||||||
|
|
||||||
echo -e "Collecting code stats (typescript errors & more)"
|
|
||||||
|
|
||||||
ERROR_COUNT_LIMIT=1
|
|
||||||
ERROR_COUNT="$(yarn run tsc --project tsconfig.json --noEmit --strict true | grep -oP 'Found \K(\d+)')"
|
|
||||||
|
|
||||||
if [ "$ERROR_COUNT" -gt $ERROR_COUNT_LIMIT ]; then
|
|
||||||
echo -e "Typescript strict errors $ERROR_COUNT exceeded $ERROR_COUNT_LIMIT so failing build"
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
|
|
@ -421,7 +421,6 @@ def lint_frontend_step():
|
|||||||
'yarn run prettier:check',
|
'yarn run prettier:check',
|
||||||
'yarn run lint',
|
'yarn run lint',
|
||||||
'yarn run typecheck',
|
'yarn run typecheck',
|
||||||
'yarn run check-strict',
|
|
||||||
],
|
],
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -5,7 +5,7 @@
|
|||||||
"outDir": "public/dist",
|
"outDir": "public/dist",
|
||||||
"rootDirs": ["public/"],
|
"rootDirs": ["public/"],
|
||||||
"allowJs": true,
|
"allowJs": true,
|
||||||
"strictNullChecks": true,
|
"strict": true,
|
||||||
"resolveJsonModule": true,
|
"resolveJsonModule": true,
|
||||||
"useUnknownInCatchVariables": false
|
"useUnknownInCatchVariables": false
|
||||||
},
|
},
|
||||||
|
Loading…
Reference in New Issue
Block a user