Skip to content

feat(ios): show debug build distance from base - #5789

Draft
saphid wants to merge 181 commits into
pingdotgg:t3code/rebuild-mobile-app-swiftfrom
saphid:saphid/swiftui-debug-build-distance
Draft

feat(ios): show debug build distance from base#5789
saphid wants to merge 181 commits into
pingdotgg:t3code/rebuild-mobile-app-swiftfrom
saphid:saphid/swiftui-debug-build-distance

Conversation

@saphid

@saphid saphid commented Aug 9, 2026

Copy link
Copy Markdown
Contributor

What changed

  • Shows a compact Debug-only build badge on the native SwiftUI workspace home bar.
  • Includes build/commit identity plus ahead/behind counts against an explicit base ref or public upstream default branch.
  • Links only public GitHub commits and degrades cleanly when distance metadata is unavailable.
  • Leaves Release/TestFlight, signing, bundle identities, and private hosts unchanged.

Fixes #5786.

Base: pingdotgg/t3code:t3code/rebuild-mobile-app-swift at e55c7ffd1.
Reviewed head: 8e9e51c380acc74050db09d8d36b75869d5f7312.

UI evidence

Before:

Before

Rebased feature evidence — build 5789, one ahead and zero behind (the follow-up changes only base-ref discovery):

Exact rebased head

Additional fallbacks:

Behind
Equal
Unavailable

Badge-to-commit interaction video

Verification

  • T3CodeTests/DebugBuildMetadataTests: 4 passed, 0 failed.
  • Full native gate: 222 tests in 28 suites passed.
  • bash -n apps/swift-ios/Scripts/install-device.sh: passed.
  • plutil -lint apps/swift-ios/Resources/Info.plist: OK.
  • Debug and Release verify-only bundle identity checks: passed.
  • Exact-head integrated iOS run exposed one semantic badge target describing build, commit, base ref, 1 ahead, and 0 behind.
  • git diff --check: passed; rebase preserved the feature patch exactly.
  • GPT-5.6 Sol high reviewed the feature and Cursor follow-up: no actionable findings; judged minimally scoped, Debug-isolated, and privacy-safe.
  • Direct Claude Opus 5 high attempt exited 1 with HTTP 429 before review; no Claude findings are claimed.
  • Prior MacroScope Git-scope finding is resolved. Cursor's upstream/HEAD finding is fixed with a verified local upstream/main fallback before origin/HEAD; an isolated Git fixture resolved upstream/main when the fork default pointed elsewhere. Current-head CI and review bots completed without further findings.

Checklist

  • Small and focused
  • Before/after and materially different UI states
  • Interaction video
  • Focused, script/plist/bundle, full native, and exact-head simulator checks
  • No personal signing, identity, private-host, or Release changes
  • Current fixed-head CI/MacroScope complete

Built with GPT-5.6 Sol in the Codex harness.

t3dotgg added 30 commits August 7, 2026 02:05
t3dotgg added 4 commits August 8, 2026 21:17
Multi-environment fixtures were spending four seconds per failed fake WebSocket request, and Xcode spent another 600 seconds collecting diagnostics after simulator launch failures. Use explicit loader receipts, inject a short fixture-only connection deadline, run one test host, skip verbose failure diagnostics, and cap individual test execution time.
Use an explicit cancellation receipt instead of a long blocking sleep in the aggregate refresh test. Treat a disconnected snapshot as a failed onboarding connection so activation and pairing cannot advance to the success screen while the selected computer is unreachable.
Reconcile the root snapshot after a partial environment activation failure, and make deep-link routing honor the activation result before navigating. This keeps the UI selection aligned with the runtime even when the target computer is unreachable.
Treat a connected recovered target as a successful activation, preserve cached thread details when the active environment did not change, and require the requested environment to be active before reporting success.
@coderabbitai

coderabbitai Bot commented Aug 9, 2026

Copy link
Copy Markdown

Important

Review skipped

Auto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro Plus

Run ID: cfa6fc26-cb02-4405-9458-c26c653b1e47

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@github-actions github-actions Bot added vouch:trusted PR author is trusted by repo permissions or the VOUCHED list. size:L 100-499 changed lines (additions + deletions). labels Aug 9, 2026
Comment thread apps/swift-ios/Scripts/install-device.sh Outdated
@saphid
saphid force-pushed the saphid/swiftui-debug-build-distance branch from fb558e1 to 1354265 Compare August 9, 2026 11:32
@saphid
saphid force-pushed the saphid/swiftui-debug-build-distance branch from 1354265 to 7b9082e Compare August 9, 2026 11:54
@saphid
saphid force-pushed the saphid/swiftui-debug-build-distance branch from 7b9082e to 888296e Compare August 10, 2026 01:20
@saphid
saphid marked this pull request as ready for review August 10, 2026 01:26

@cursor cursor Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes using high effort and found 1 potential issue.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit 888296e. Configure here.

Comment thread apps/swift-ios/Scripts/install-device.sh
macroscopeapp[bot]
macroscopeapp Bot previously approved these changes Aug 10, 2026
@macroscopeapp

macroscopeapp Bot commented Aug 10, 2026

Copy link
Copy Markdown
Contributor

Approvability

Verdict: Approved 8e9e51c

This PR adds a debug-only badge showing git commit info and distance from base branch. All Swift code is wrapped in #if DEBUG and shell script changes only run for Debug configuration, so production builds are completely unaffected. The change is well-scoped and includes tests.

You can customize Macroscope's approvability policy. Learn more.

@saphid
saphid force-pushed the saphid/swiftui-debug-build-distance branch from 888296e to 8e9e51c Compare August 10, 2026 01:43
@macroscopeapp
macroscopeapp Bot dismissed their stale review August 10, 2026 01:43

Dismissing prior approval to re-evaluate 8e9e51c

@saphid

saphid commented Aug 10, 2026

Copy link
Copy Markdown
Contributor Author

@t3dotgg Ready for your review against the current SwiftUI branch. Final head 8e9e51c; focused/full native, script, bundle, and integrated evidence are in the PR body. Current-head CI and MacroScope are green, and all review threads are resolved.

@t3dotgg
t3dotgg force-pushed the t3code/rebuild-mobile-app-swift branch from 4cb3307 to 497f54f Compare August 10, 2026 03:58
@saphid

saphid commented Aug 10, 2026

Copy link
Copy Markdown
Contributor Author

Dependency-safe rebuild is complete and preserved at saphid/swiftui-debug-distance-integration-stack (5230a96b4). Do not update this Theo-targeted PR yet: the tested head composes three still-open foundations in required order—#5790 versions → #5970 monotonic build/install → #5972 shared Debug chrome/predicate. Updating now would duplicate all three diffs.

The eventual unique PR commit is 5230a96b4 (9 files, +312/-2): truthful Debug source + owner-branch distance in Settings/About, no second Home badge, no second version formatter, no second Debug detector, and metadata appended to #5970’s build settings. It never silently compares against upstream/main; missing/shallow/no-upstream states stay honest. Release has no T3Git fields or rows.

Verification on exact integration stack: resolver shell suite; monotonic shell suite; focused Swift 4/4; full native 234 tests/31 suites; Debug build/run and semantic Settings proof; Release build with normal name/version and empty Debug metadata; git diff --check clean. Tailnet-only video: https://alexs-macbook-pro-1.tail4e5636.ts.net:10014/debug-settings-about.mp4

Conflict classification: stale history/code plus feature-placement overlap (old second Home badge conflicts with #5972 visual ownership). Landing plan: merge #5790, #5970, #5972; rebase only 5230a96b4 onto refreshed Theo; then force-with-lease this PR. Opus review unavailable at confirmed 429 quota boundary; no verdict claimed.

@saphid
saphid marked this pull request as draft August 10, 2026 14:44
@github-actions github-actions Bot added size:XXL 1,000+ changed lines (additions + deletions). and removed size:L 100-499 changed lines (additions + deletions). labels Aug 10, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size:XXL 1,000+ changed lines (additions + deletions). vouch:trusted PR author is trusted by repo permissions or the VOUCHED list.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants