[DRAFT] feat: skip type checking by default #11810
Closed
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.
Closes: #11340
This PR:
--check
flag--no-check
flag--check
can be used to type checkThe tests still need to be updated for not type checking by default.
A couple of points of discussion:
deno test
does not type check by default. It be more logical to implicitly enable--check
fordeno test
. This does mean this subcommand would differ in default flags than other subcommands, and we would not remote--no-check
fordeno test
.deno cache
reflects the others, skipping type checking by default. We need to determine how it all relates todeno check
#11786 (deno check
). I don't thinkdeno check
would replace the use of--check
flag, as there are lots of subcommands where people would not want to have to invoke 2 subcommands just to check their documents, as well as there is the challenge that we implicitly type check worker scripts contextually, so unless we add flags todeno check
for the type of code it is checking, some code will fail.warn_check
flag inProgramState
feels hacky to me, but I don't have any great ideas how better to manage it. We need it, as there are certain commands where the methods get called > 1 times, causing multiple warnings to be printed if we don't have a flag.