Skip to content

fix(ios): Find .xcode.env in the debug symbols phase under SwiftPM - #6911

Merged
alwx merged 2 commits into
mainfrom
alwx/bugfix/spm-xcode-env
Oct 19, 2026
Merged

alwx merged 2 commits into
mainfrom
alwx/bugfix/spm-xcode-env

Conversation

@alwx

@alwx alwx commented Oct 19, 2026

Copy link
Copy Markdown
Contributor

📢 Type of change

  • Bugfix
  • New feature
  • Enhancement
  • Refactoring

📜 Description

The Expo plugin "Upload Debug Symbols to Sentry" phase now uses $SRCROOT to find .xcode.env when PODFILE_DIR and PODS_ROOT are not set. The order is PODFILE_DIR, then PODS_ROOT/.., then SRCROOT. Thus CocoaPods projects do not change.

💡 Motivation and Context

After react-native spm add --deintegrate, the project has no CocoaPods, so PODS_ROOT is empty. The phase looked for /../.xcode.env and did not find NODE_BINARY. When Xcode starts from the Dock, node is not on PATH, so the phase failed. The SwiftPM build phases of React Native 0.87 use $SRCROOT/.xcode.env for the same reason.

Related to #5780.

💚 How did you test it?

Added two shell tests in modifyXcodeProject.test.ts. One runs the phase with only SRCROOT set and no node on PATH. This test failed before the fix. The other test makes sure that PODS_ROOT has priority over SRCROOT.

📝 Checklist

  • I added tests to verify changes.
  • No new PII added or SDK only sends newly added PII if sendDefaultPII is enabled.
  • I updated the docs if needed.
  • I updated the wizard if needed.
  • All tests passing.
  • Public API changes reviewed by another Mobile SDK team member or implemented according to the develop docs spec.
  • No breaking changes.

@github-actions

github-actions Bot commented Oct 19, 2026 •

Copy link
Copy Markdown
Contributor

Semver Impact of This PR

⚪ None (no version bump detected)

📋 Changelog Preview

This is how your changes will appear in the changelog.
Entries from this PR are highlighted with a left border (blockquote style).


  • fix(ios): Find .xcode.env in the debug symbols phase under SwiftPM by alwx in #6911
  • chore(deps): bump actions/create-github-app-token from 3.2.0 to 3.3.0 by dependabot in #6908
  • chore(deps): bump getsentry/craft/.github/workflows/changelog-preview.yml from 2.33.1 to 2.35.0 by dependabot in #6907
  • chore(sample): Bump React Native sample to 0.88.0 by antonis in #6910
  • chore(deps): bump actions/setup-java from 6.0.1 to 6.1.0 by dependabot in #6909
  • chore(deps): bump the codeql-action group with 3 updates by dependabot in #6905
  • chore(deps): update Sentry Android Gradle Plugin to v6.24.0 by github-actions in #6902
  • chore(deps): bump @appium/support from 7.0.6 to 7.2.8 by dependabot in #6897
  • ci(e2e): Remove app metrics job and performance-tests by antonis in #6896

🤖 This preview updates automatically when you update the PR.

@alwx
alwx marked this pull request as ready for review October 19, 2026 09:24
@antonis antonis added the ready-to-merge Triggers the full CI test suite label Oct 19, 2026
@sentry

sentry Bot commented Oct 19, 2026

Copy link
Copy Markdown

📲 Install Builds

Android

🔗 App Name App ID Version Configuration
Sentry RN io.sentry.reactnative.sample 8.31.0 (111) Release

⚙️ sentry-react-native Build Distribution Settings

@antonis antonis 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.

LGTM once the tests go 🟢

@alwx
alwx merged commit d082ef1 into main Oct 19, 2026
119 of 126 checks passed
@alwx
alwx deleted the alwx/bugfix/spm-xcode-env branch October 19, 2026 12:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ready-to-merge Triggers the full CI test suite

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants