-
Notifications
You must be signed in to change notification settings - Fork 522
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Validate ts project #1722
Validate ts project #1722
Conversation
81ce6a1
to
e4bc646
Compare
…tsconfig settings
e4bc646
to
6cef733
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice. This is a beauty.
The only nit I would add is a ts_project test where that is intentionally mismatched with validate = False
.
console.error('You can automatically fix this by running:'); | ||
console.error(` npx buildozer ${buildozerCmds.map(c => `'${c}'`).join(' ')} ${target}`); | ||
console.error('Or to suppress this error, run:'); | ||
console.error(` npx buildozer 'set validate False' ${target}`); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: user may not have buildozer? also add simpler manual instructions?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Even worse: https://www.npmjs.com/package/buildozer
I think I'd better make this npx @bazel/buildozer
(note, that works even if you don't have it installed, so I think it's fine to keep the error message short since it should work in all cases)
Looking this PR. another feature to add to the list to make it this feature compatible to ts_library is the |
expected_diagnostics is annoying since you have to regex anyway. plus the kind of failure we want to test here is the action before tsc. Could we have a generic feature for run_node or npm_package_bin for expected failure? |
Yes. Something with that could integration with run_node would be ideal. nodejs_test has expected_exit code but we have nothing for build rule failure testing |
…es the tsconfig settings
PR Checklist
Please check if your PR fulfills the following requirements:
PR Type
What kind of change does this PR introduce?
What is the current behavior?
Issue Number: N/A
What is the new behavior?
Does this PR introduce a breaking change?
Other information