Repository navigation
Conversation
@expo/metro-runtime before 58.0.15 wraps fetch in Expo Router apps and drops the expo.builtin marker. Fall back to the wrapper's own marker on Expo SDK 56+ unless the app opted out with EXPO_PUBLIC_USE_RN_FETCH. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Contributor
Semver Impact of This PR⚪ None (no version bump detected) 📋 Changelog PreviewThis is how your changes will appear in the changelog.
🤖 This preview updates automatically when you update the PR. |
There was a problem hiding this comment.
✅ Bugbot reviewed your changes and found no new issues!
Comment @cursor review or bugbot run to trigger another review on this PR
Reviewed by Cursor Bugbot for commit b429007. Configure here.
antonis
marked this pull request as ready for review
October 29, 2026 13:01
antonis
requested review from
alwx and
buenaflor
and removed request for
a team
October 29, 2026 13:01
📲 Install BuildsAndroid
|
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.
📢 Type of change
📜 Description
isExpoFetchEnabled()checks for theexpo.builtinmarker onglobalThis.fetch. In Expo Router apps,@expo/metro-runtimewrapsfetchto support relative URLs, and before 58.0.15 the wrapper dropped that marker. The SDK then missesexpo/fetch, so fetch tracing and fetch breadcrumbs stay off by default.When the marker is missing,
isExpoFetchEnabled()now also returnstrueif:globalThis.fetchhas the wrapper's own marker (expo.polyfillFetchWithWindowLocation),expo/fetch), read from the nativeExponentConstants.manifest(a JSON string on Android), andEXPO_PUBLIC_USE_RN_FETCH. It's read the same way as Expo's own runtime, so both resolve the same value after babel-preset-expo.If any of these can't be determined, it returns
false, which is the previous behavior.This also applies the
expo/fetchHTTP timings default from #6912 to these apps, sotraceFetch: trueno longer needsenableHTTPTimings: falseto avoid leaking listeners.💡 Motivation and Context
Fixes #6874
💚 How did you test it?
isExpoFetchEnabled(): SDK 56/57/58, SDK 55, unknown SDK version, manifest as a JSON string and as invalid JSON,EXPO_PUBLIC_USE_RN_FETCHset to1,trueand0.fetchproduced nohttp.clientspan and no fetch breadcrumb.http.clientspan without HTTP timings, and afetchbreadcrumb.EXPO_PUBLIC_USE_RN_FETCH=1: onehttp.clientspan from XHR and only anxhrbreadcrumb (no duplicate).📝 Checklist
sendDefaultPIIis enabled.🔮 Next steps