Repository navigation
fix(compiler): resolve an absolute tsconfig path - #3620
Merged
kamilmysliwiec merged 1 commit intoOct 12, 2026
Merged
Conversation
TsConfigProvider joined the given path onto the working directory, so an absolute path (e.g. `nest build -p /app/tsconfig.build.json`) pointed at a file that does not exist and every builder failed with "Could not find TypeScript configuration file".
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
PR Checklist
PR Type
What is the current behavior?
Issue Number: N/A
An absolute tsconfig path fails for every builder:
TsConfigProviderbuilds the path withjoin(process.cwd(), configFilename), which appends an absolute path to the working directory.BuildActioncalls the provider before it selects a builder, so the command stops there. This is also why the absolute-path case described in #3595 (webpack) and fixed in #3542 (rspack) still cannot be reached from the command line.What is the new behavior?
The provider uses
resolve, which keeps an absolute path as it is. Relative paths resolve as before.Does this PR introduce a breaking change?
Other information
Validated on macOS with Node 24.21.0:
npm run build,npm run lintand the Prettier check on the changed files passed. Lint reports the existing unusedyellowimport inrunner.factory.ts.nest build -p <absolute path>produced the output with thetsc,swc,webpackandrspackbuilders, andnest start --watch -p <absolute path>started the application. A relative path still builds.The
test:e2esuite and Windows were not run locally.