Skip to content

Commit 52f8eb3

Browse files
fix(webhooks): split webhook-ingest tsconfig so Docker build has rootDir
TS 6 requires explicit rootDir when the inferred common source directory collapses to a single subtree. In the Docker build context only src/ is COPYed (no test/), so tsc infers rootDir=./src and refuses to emit unless told so explicitly. Split: tsconfig.json now only includes src/ (compilation entry), and a new tsconfig.test.json overlays src/ + test/ + *.config.ts for tsc --noEmit. The typecheck script points at the test config so test code keeps being checked at PR time. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
1 parent bec650d commit 52f8eb3

3 files changed

Lines changed: 15 additions & 4 deletions

File tree

server/webhook-ingest/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
"format:check": "biome check --formatter-enabled=true --linter-enabled=false src test",
1616
"lint": "biome lint src test",
1717
"lint:fix": "biome lint --write src test",
18-
"typecheck": "tsc --noEmit",
18+
"typecheck": "tsc -p tsconfig.test.json --noEmit",
1919
"validate": "pnpm run typecheck && pnpm run lint && pnpm run test"
2020
},
2121
"dependencies": {

server/webhook-ingest/tsconfig.json

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@
2424
"resolveJsonModule": true,
2525
"isolatedModules": true,
2626
"outDir": "./dist",
27+
"rootDir": "./src",
2728
"declaration": true,
2829
"sourceMap": true,
2930
"types": [
@@ -32,9 +33,7 @@
3233
"skipLibCheck": true
3334
},
3435
"include": [
35-
"src/**/*",
36-
"test/**/*",
37-
"*.config.ts"
36+
"src/**/*"
3837
],
3938
"exclude": [
4039
"node_modules",
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
{
2+
"extends": "./tsconfig.json",
3+
"compilerOptions": {
4+
"rootDir": null,
5+
"noEmit": true
6+
},
7+
"include": [
8+
"src/**/*",
9+
"test/**/*",
10+
"*.config.ts"
11+
]
12+
}

0 commit comments

Comments
 (0)