Skip to content

[codex] Align iOS dev auth with Mac dev builds - #5944

Closed
azooz2003-bit wants to merge 1 commit into
mainfrom
codex/ios-dev-auth-realm
Closed

azooz2003-bit wants to merge 1 commit into
mainfrom
codex/ios-dev-auth-realm

Conversation

@azooz2003-bit

@azooz2003-bit azooz2003-bit commented Jun 12, 2026 •

Copy link
Copy Markdown
Collaborator

Summary

Fixes iOS dev pairing account verification by aligning iOS DEBUG/dev auth with the Mac dev build auth realm:

  • defaults iOS dev builds to production Stack auth
  • bakes CMUXAuthEnvironment into the iOS app Info.plist from ios/scripts/reload.sh
  • keeps intentional local auth testing available through CMUX_DEV_AUTH_ORIGIN=local / CMUXAuthEnvironment=development
  • adds focused coverage for the default and local override

Why

The QR transport path can succeed while account verification fails if the Mac dev build is signed into production Stack auth but the iOS DEBUG build mints a token from the development Stack project. That produces the observed state: macOS reports the iPhone connected, then iOS shows "Couldn't verify your account." Both dev builds now default to the same auth realm.

Validation

  • bash -n ios/scripts/reload.sh
  • In the main checkout, ios/scripts/reload.sh --tag ios-close-workspace --device-only built and installed successfully with CMUX_AUTH_ENVIRONMENT=production
  • Verified the built iOS app Info.plist contains CMUXAuthEnvironment=production
  • Clean temporary worktree build was attempted but blocked by missing local GhosttyKit.xcframework artifact in /tmp, not by this patch

View with Codesmith Autofix with Codesmith
Need help on this PR? Tag /codesmith with what you need. Autofix is disabled.


Summary by cubic

Aligns iOS DEBUG/dev builds with the Mac dev build by defaulting to production Stack auth, with an opt-in local override. Fixes the “Couldn't verify your account” pairing failure caused by mismatched auth realms.

  • Bug Fixes
    • Default iOS dev builds to production auth; opt-in local dev via CMUX_DEV_AUTH_ORIGIN=local or CMUXAuthEnvironment=development.
    • Resolve auth env in MobileAuthComposition from Info.plist and LocalConfig.plist, ignoring empty/unexpanded values; added tests and made CMUXAuthEnvironment Equatable.
    • Plist/config wiring: added CMUXAuthEnvironment and ApiBaseURL to Info.plist; set CMUX_AUTH_ENVIRONMENT=production in Shared.xcconfig; reload.sh sets CMUX_AUTH_ENVIRONMENT from CMUX_DEV_AUTH_ORIGIN (auto/prod/local).

Written for commit 654c4bc. Summary will update on new commits.

Review in cubic

@vercel

vercel Bot commented Jun 12, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
cmux Ready Ready Preview, Comment Jun 12, 2026 4:31am
cmux-staging Building Building Preview, Comment Jun 12, 2026 4:31am

@coderabbitai

coderabbitai Bot commented Jun 12, 2026

Copy link
Copy Markdown

Important

Review skipped

Draft detected.

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: Path: .coderabbit.yaml

Review profile: ASSERTIVE

Plan: Pro

Run ID: 20a6a890-6c80-4782-a5a7-3d3dcba4a2ac

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
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch codex/ios-dev-auth-realm

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 and usage tips.

This branch was successfully deployed

1 active deployment
Preview – cmux — 654c4bc5 Deployed Jun 12, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

stale-revisit Closed after 30+ days without activity; preserved for possible revisit or reopening.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants