fix: install pnpm deps in hoisted mode + declare @babel/types (#24288) (CP: 25.0)#24296
Merged
fix: install pnpm deps in hoisted mode + declare @babel/types (#24288) (CP: 25.0)#24296
Conversation
… (CP: 25.0) Manual port of d9290f8 from main. 25.0 is pre-flow-build-tools refactor (#23161), so the FrontendTools.java, FrontendToolsTest.java, NodeUpdaterTest.java and TaskRunPnpmInstallTest.java edits all apply under flow-server/ rather than flow-build-tools/. Adjusted for 25.0's dep-graph: @babel/types is pinned to 7.28.5 to match @babel/preset-react's version on this branch (main pins to 7.29.0 to match @babel/core which is not declared on 25.0). @babel/core and @babel/plugin-transform-react-jsx-development from the main commit are not added — they are not declared as direct deps on 25.0 and the React function location plugin only imports @babel/types. The .npmrc and FrontendTools changes that switch pnpm to hoisted mode apply unchanged. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
vaadin-review-bot
previously approved these changes
May 8, 2026
Collaborator
Author
|
This PR is eligible for auto-merging policy, so it has been approved automatically. If there are pending conditions, auto merge (with 'squash' method) has been enabled for this PR [Message is sent from bot] |
Test Results1 319 files 1 319 suites 1h 23m 17s ⏱️ Results for commit 1019bf2. ♻️ This comment has been updated with latest results. |
Collaborator
Author
|
This PR is eligible for auto-merging policy, so it has been approved automatically. If there are pending conditions, auto merge (with 'squash' method) has been enabled for this PR[Message is sent from bot] |
vaadin-review-bot
approved these changes
May 8, 2026
|
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.



Cherry-pick of #24288 (commit d9290f8) from main to 25.0.
Summary
Same fix as #24288: switches pnpm install to hoisted (flat npm-style)
layout so transitive npm deps (
@babel/types,@lit/reactive-element,cookie,set-cookie-parser,@preact/signals-react/runtime) arealways reachable from project root, eliminating the
vite-basicsIThang and similar symptoms.
Adjustments for 25.0
This branch is pre-
flow-build-toolsrefactor (#23161), so all theJava files the original commit touches (
FrontendTools.java,FrontendToolsTest.java,NodeUpdaterTest.java,TaskRunPnpmInstallTest.java) live underflow-server/here. Theedits are otherwise identical.
Two version adjustments to match this branch's dep graph:
@babel/typespinned to7.28.5(matching@babel/preset-reactalready in
vite/package.json) instead of main's7.29.0. 25.0does not declare
@babel/core, so version coherence is anchored topreset-react.Skipped
@babel/coreand@babel/plugin-transform-react-jsx-developmentdeclarations from the main commit — not declared as direct deps on
25.0, and the React function location plugin only imports
@babel/types.Everything else is identical:
flow-server/.../npmrc: addsnode-linker=hoisted.FrontendTools.java: replaces--shamefully-hoist=trueCLI flagwith
--config.node-linker=hoisted.Test plan
it-tests (1)andit-tests (2)).mvn -pl flow-server test -Dtest=NodeUpdaterTest,TaskRunPnpmInstallTest,FrontendToolsTestpasses.node_modules/.pnpm/does not exist (or is empty);node_modules/@babel/types/andnode_modules/@lit/reactive-element/exist as real directories at the project root.🤖 Generated with Claude Code