Repository navigation
fix(build): prepare shared declarations before parallel plugins - #46024
Open
mikebridge wants to merge 1 commit into
Open
mikebridge wants to merge 1 commit into
mikebridge wants to merge 1 commit into
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #46024 +/- ##
=======================================
Coverage 85.00% 85.00%
=======================================
Files 3080 3080
Lines 209266 209266
Branches 49296 49296
=======================================
Hits 177895 177895
Misses 27989 27989
Partials 3382 3382
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
mikebridge
marked this pull request as ready for review
November 4, 2026 23:30
Contributor
This branch has not been deployed
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.
SUMMARY
TL;DR: Build shared TypeScript projects once before starting parallel plugin builds, so plugins do not write the same declaration files concurrently.
Background:
plugins:buildstarts three per-packagetsc --buildprocesses. Each plugin references the same core and chart-controls projects, and each compiler can rebuild those references. The Lerna package schedule does not serialize these TypeScript reference builds.Problem: frontend lint has failed with missing declarations or inconsistent shared types in separate plugins:
Changes: compile the three shared referenced projects in one
tsc --buildinvocation before the existing parallel stage. TypeScript traverses their dependencies in order. The plugin stage retains its concurrency and sees up-to-date shared declarations. Babel output, per-plugin type checking and root type checking remain unchanged. Filtered builds also prepare these shared prerequisites.BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF
Not applicable; build scheduling only.
TESTING INSTRUCTIONS
npm run test -- --runInBand spec/scripts/build.test.ts: exercises default,--skip-lib, filtered builds, and stopping before plugins when shared compilation fails. The tests fail without the new phase.npm run plugins:build -- --skip-lib && npm run type.The exact intermittent CI errors were not reproduced locally. Concurrent writes to the same shared projects were confirmed with verbose compiler logs on master; this change removes that overlap. After a fresh locked dependency install, three clean fixed builds passed in 15.8/15.8/15.7 seconds versus 17.0 seconds before, with all 2,242 declaration files/maps byte-for-byte identical. Root type checking and changed-file hooks passed. Validation was on macOS with Node 24; Linux CI remains necessary.
ADDITIONAL INFORMATION