-
Notifications
You must be signed in to change notification settings - Fork 3.1k
chore(node): remove redundant experimental type-stripping flags #11317
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
Merged
Merged
Changes from all commits
Commits
Show all changes
4 commits
Select commit
Hold shift + click to select a range
609d60a
chore(node): remove redundant experimental type-stripping flags
cv 35a116a
test: refresh Pi qualification and align CLI timeout budgets
cv 34b1cb0
ci: require supported Node versions for native TypeScript
cv bc37a43
test: stop pinning Node selector text in workflow checks
cv File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
Oops, something went wrong.
Oops, something went wrong.
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.
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.
🩺 Stability & Availability | 🟠 Major | ⚡ Quick win
🔎 Supported by static analysis
🤖 get_repo_knowledge executed:
get_repo_knowledge NVIDIA/NemoClaw /tmp/coderabbit-repo-knowledge/nvidia-nemoclaw-0b48f24a/conventions /tmp/coderabbit-repo-knowledge/nvidia-nemoclaw-0b48f24a/learningsLength of output: 47383
🏁 Script executed:
Repository: NVIDIA/NemoClaw
Length of output: 14792
🌐 Web query:
actions/setup-node node-version 22 semver cached toolcache exact version resolution official documentation💡 Result:
The actions/setup-node action handles Node.js version resolution, semver matching, and caching according to the following principles [1][2][3]: Version Resolution and Semver The node-version input supports Semantic Versioning (semver) notation [1][4]. When you provide a version spec like 22 (which resolves to the latest available 22.x version) or an exact version like 22.17.1, the action uses the semver package to determine the best match [1][3]. Local Cache Behavior By default (check-latest: false), the action first checks the local runner environment for a version that satisfies the semver spec [2][4]. If a match is found in the local tool cache, it uses that version without attempting to download a new one [2]. This behavior ensures stability and faster workflow execution by avoiding network requests [2]. Downloading Versions If the required version is not found in the local cache, the action proceeds to download it [1][2]. It primarily fetches versions from the actions/node-versions repository [1]. If that fails or the specific version is not available there, it falls back to downloading directly from the official Node.js distribution (nodejs.org/dist) [1][2]. Enforcing Exact Versions If you require an exact version (e.g., 22.17.1) and want to ensure the action does not use a cached version that might technically satisfy a broader semver range (though in practice it will look for the specific version), or if you want to ensure you are always using the latest update available online, you can set the check-latest input to true [2][4]. When check-latest is true, the action will check if the locally cached version is the latest one available that satisfies your semver spec; if it is not, it will download the newer version [2]. Summary of Key Inputs - node-version: Accepts semver ranges (e.g., 22, 22.17.1) [1][4]. - check-latest: Defaults to false. Set to true to force a check for the latest available version online [2][4]. - node-version-file: Allows specifying a file (like.nvmrc or package.json) to resolve the version [1][2]. If both node-version and node-version-file are provided, node-version takes precedence [2][4].
Citations:
🌐 Web query:
Node.js v22.18.0 default type stripping official documentation TypeScript .mts💡 Result:
In Node.js v22.18.0, type stripping is enabled by default, allowing the runtime to execute TypeScript files natively by removing erasable type annotations [1][2][3]. Regarding.mts files and type stripping: 1. Module System: Node.js handles.mts files as ES Modules, similar to how it treats.mjs files [1][4]. 2. Default Behavior: Because type stripping is enabled by default in v22.18.0, Node.js will automatically attempt to strip types and execute.mts files when you run them directly (e.g., node file.mts) [1][2]. 3. Limitations: Type stripping is "lightweight," meaning it only supports syntax that can be removed without changing the runtime JavaScript (such as type annotations, interfaces, and import types) [1][5]. Features requiring transpilation or code generation—such as enums, namespaces with runtime code, or parameter properties—are not supported by default [1][5]. If your.mts file uses these specific features, you may need to use the --experimental-transform-types flag to enable the necessary transformation [1][4]. 4. Configuration: Node.js ignores tsconfig.json files during this process; therefore, settings like path aliases or down-leveling JavaScript syntax are not supported [1][6]. 5. Disabling: If you wish to disable the default type stripping behavior, you can use the --no-experimental-strip-types CLI flag [1][2][3]. For full TypeScript support, including features that require code generation or custom configuration, you should continue using a dedicated TypeScript transpiler [1][5][7].
Citations:
🏁 Script executed:
Repository: NVIDIA/NemoClaw
Length of output: 4948
🏁 Script executed:
Repository: NVIDIA/NemoClaw
Length of output: 25778
🏁 Script executed:
Repository: NVIDIA/NemoClaw
Length of output: 11070
Pin the Node.js runtime to
22.19.0.actions/setup-nodemay select any cached Node 22.x release fornode-version: "22". Releases before v22.18.0 do not enable default TypeScript stripping. The listednode *.mtscommands can therefore fail before execution. Set all three setup steps in.github/workflows/candidate-compatibility.yamland the setup step in.github/actions/ci-static-checks/action.yamltonode-version: "22.19.0"to satisfy the repository’sengines.nodecontract.📍 Affects 2 files
.github/actions/ci-static-checks/action.yaml#L25-L25(this comment).github/workflows/candidate-compatibility.yaml#L76-L76.github/workflows/candidate-compatibility.yaml#L92-L92.github/workflows/candidate-compatibility.yaml#L168-L168.github/workflows/candidate-compatibility.yaml#L215-L215.github/workflows/candidate-compatibility.yaml#L294-L294.github/workflows/candidate-compatibility.yaml#L334-L334.github/workflows/candidate-compatibility.yaml#L356-L356.github/workflows/candidate-compatibility.yaml#L418-L418🤖 Prompt for AI Agents