fix: accept SwiftBuild-backend bundle layout in release stage checks#59
Merged
Merged
Conversation
verify-stage hardcoded the classic flat SwiftPM resource layout (<bundle>/viewer/index.html, <bundle>/Resources/*.apk). SwiftBuild- backend toolchains (Xcode 26.6+/27) produce macOS-shaped bundles with resources under Contents/Resources, so staging a payload built there failed on the Viewer-SPA contract even though the resources were present. Resolve each bundle's resource root the way Foundation does (Contents/Resources when it exists, bundle root otherwise) before running the contracts; runtime lookups already go through the Bundle API and are layout-agnostic. Found by a /bump-version-dev local install on Xcode 27 Beta 4; the staged v0.11.0-shaped payload passed verify-stage after the fix and was smoke-tested live (tap-by-id + describe-ui on a booted simulator, Viewer SPA served from the deep layout). Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Signed-off-by: onevcat <onevcat@gmail.com>
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
verify-stagehardcoded the classic flat SwiftPM resource layout (<bundle>/viewer/index.html,<bundle>/Resources/sim-use-device-bridge.apk). SwiftBuild-backend toolchains (Xcode 26.6+/27) produce macOS-shaped bundles with resources underContents/Resources, so staging a payload built on Xcode 27 B4 failed the Viewer-SPA contract even though every resource was present — blocking the upcoming v0.11.0 release.Fix
New
bundle_resource_root()helper resolves each staged bundle's resource root the way Foundation does (Contents/Resourceswhen present, bundle root otherwise); the Viewer-SPA and bundled-APK contracts run against that root. Both layouts pass; the contracts still trip when resources are genuinely missing.Runtime needed no change: all three lookup sites (
AndroidDeviceController.bundledAPKPath,ViewerStaticFiles.rootURL,Initskill source) go through the Bundle API, which is layout-agnostic.Verification
/bump-version-devon Xcode 27 Beta 4: staging previously failed at the Viewer contract; after the fixverify-stagepasses (Android bridge APK 4511756 bytes, Viewer 2 assets).tap --id+describe-ui+ orientation calibration on a booted iOS 27 simulator through the installed binary, and the Viewer SPA servedindex.html(HTTP 200) from the deep layout.🤖 Generated with Claude Code