diff --git a/.github/workflows/gradual-strict-null-checks.yml b/.github/workflows/gradual-strict-null-checks.yml
index 775e2b6091..f1ab17245e 100644
--- a/.github/workflows/gradual-strict-null-checks.yml
+++ b/.github/workflows/gradual-strict-null-checks.yml
@@ -47,13 +47,12 @@ jobs:
--data "{ \"body\": \"${1}\" }"
}
- sed -i 's/\/\/\s*"strictNullChecks":\s*true,/"strictNullChecks": true,/' "current/tsconfig.json"
- sed -i 's/\/\/\s*"strictNullChecks":\s*true,/"strictNullChecks": true,/' "main/tsconfig.json"
+ YARN_1="yarn --mutex network --cwd ./current"
+ YARN_2="yarn --mutex network --cwd ./main"
- yarn --mutex network --cwd ./current 2> .stderr-current > .out-current &
+ $YARN_1 install --ignore-scripts &> /dev/null && $YARN_1 build --strictNullChecks true 2> .stderr-current > .out-current &
pid1=$!
-
- yarn --mutex network --cwd ./main 2> .stderr-main > .out-main &
+ $YARN_2 install --ignore-scripts &> /dev/null && $YARN_2 build --strictNullChecks true 2> .stderr-main > .out-main &
pid2=$!
# wait for the processes that are expected to fail
@@ -66,7 +65,7 @@ jobs:
MAIN=$(grep "Found [0-9]* errors" .out-main | sed 's/Found \(.*\) errors in .* files./\1/')
if [ $CURRENT -gt $MAIN ]; then
- comment "After enabling [\`strictNullChecks\`](https://www.typescriptlang.org/tsconfig#strictNullChecks) this PR would be **increasing** the number of null check errors from ${MAIN} to ${CURRENT}.
Make sure your branch is up-to-date with ${MAIN_BRANCH} and **check the diff in the console output** to gather more details."
+ comment "After enabling [\`strictNullChecks\`](https://www.typescriptlang.org/tsconfig#strictNullChecks) this PR would be **increasing** the number of null check errors from ${MAIN} to ${CURRENT}.
Make sure your branch is up-to-date with ${MAIN_BRANCH} and **check the diff in the console output** to pinpoint the offending files."
diff .out-current .out-main
exit 1
else
diff --git a/package.json b/package.json
index 0cf3cc53ff..c5fe8169a2 100644
--- a/package.json
+++ b/package.json
@@ -35,9 +35,9 @@
"lint": "eslint ./src",
"local:package": "del-cli --force build && mkdir build && cp -r dist docs CHANGELOG.md LICENSE README.md package.json build",
"prebuild:watch": "yarn run clean",
- "build:watch": "tsc -w",
+ "build:watch": "tsc -w --strictNullChecks false",
"prebuild": "yarn run clean",
- "build": "yarn run copy-templates && tsc --pretty",
+ "build": "yarn run copy-templates && tsc --pretty --strictNullChecks false",
"prepare": "node scripts/husky-install && cd frontend && yarn && cd .. && yarn run build",
"test": "NODE_ENV=test PORT=4243 jest",
"test:unit": "NODE_ENV=test PORT=4243 jest --testPathIgnorePatterns=src/test/e2e --testPathIgnorePatterns=dist",
diff --git a/tsconfig.json b/tsconfig.json
index 3b9362f856..3a8552b43a 100644
--- a/tsconfig.json
+++ b/tsconfig.json
@@ -27,7 +27,7 @@
/* Strict Type-Checking Options */
// "strict": true, /* Enable all strict type-checking options. */
// "noImplicitAny": true, /* Raise error on expressions and declarations with an implied 'any' type. */
- // "strictNullChecks": true, /* Enable strict null checks. */
+ "strictNullChecks": true /* Enable strict null checks. */,
// "strictFunctionTypes": true, /* Enable strict checking of function types. */
"strictBindCallApply": true /* Enable strict 'bind', 'call', and 'apply' methods on functions. */,
// "strictPropertyInitialization": true, /* Enable strict checking of property initialization in classes. */