Repository navigation
copy native build files from target, not file list - #11771
Merged
Merged
Conversation
Richard Knoll (riknoll)
requested review from
a team
and
a max review from Copilot
November 19, 2026 00:16
Richard Knoll (riknoll)
enabled auto-merge
November 19, 2026 00:18
Joey Wunderlich (jwunderl)
approved these changes
Nov 19, 2026
Contributor
There was a problem hiding this comment.
🟡 Changes recommended
Bundled build-file changes can leave projectCompileSha unchanged, allowing fallback cache lookups to return binaries built with outdated files.
5 open issues
Include bundled build inputs in the compile cache identity · New Preserve local build files for trusted file dependencies · New Retain metadata for build-file-only bundled dependencies · New Resolve bundled packages by package identity, not directory name · New Restore only build files selected by getConfigFiles · New
What changed in this PR
Updates native extension generation to recover build configuration files from target bundles when backend requests omit them, addressing the Raspberry Pi build failure in common packages.
Changes:
- Restore bundled
Makefile,sdkconfig.defaults, andCMakeLists.txtfiles, giving bundled contents precedence over supplied copies. - Add regression coverage for restoration, input immutability, and native extension hash changes when bundled contents change.
| File | Description |
|---|---|
tests/cli-test/clirunner.ts |
Tests bundled-file restoration, override handling, dependency sources, and hash changes. |
pxtlib/shared/extensioninfo.ts |
Restores bundled build-file names and reads their contents from the target bundle. |
Review effort: Max
Comment on lines
+179
to
+180
| const bundledFile = bundledPackages[id] && bundledPackages[id][name]; | ||
| if (bundledFile != null) return bundledFile; |
Comment on lines
+179
to
+180
| const bundledFile = bundledPackages[id] && bundledPackages[id][name]; | ||
| if (bundledFile != null) return bundledFile; |
Comment on lines
+229
to
+231
| if (pkg.path) { | ||
| const id = pkg.path.slice("pxt_modules/".length, -1); | ||
| const bundledFiles = bundledPackages[id]; |
Comment on lines
+230
to
+231
| const id = pkg.path.slice("pxt_modules/".length, -1); | ||
| const bundledFiles = bundledPackages[id]; |
Comment on lines
+233
to
+234
| if (bundledFiles && bundledFiles[name] != null && pkg.files.indexOf(name) < 0) | ||
| pkg.files.push(name); |
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.


fixes the raspberry pi build failure in common packages