feat(sentry): symbolicate backend errors in debug builds without uploading sourcemaps#188
Merged
Merged
Conversation
…ading sourcemaps Debug builds now ship the embedded Node backend's sourcemap alongside the bundle and pass Node's `--enable-source-maps`, so backend errors are remapped to original positions in-process and reach Sentry symbolicated — no sourcemap upload or Sentry auth token needed. Release builds are unchanged: maps stay out of the app and are uploaded by the consumer via `comapeo-rn-upload-sourcemaps`. Android ships the debug map colocated in the `src/debug` asset tree (debug variants only). iOS uses a Debug-only `ComapeoCoreSourcemaps` companion pod (`:configurations => ['Debug']`) whose maps merge next to the bundle in the app; `expo-module.config.json` pins `apple.podspecPath` so it is never autolinked. The native side passes `--enable-source-maps` under `BuildConfig.DEBUG` / `#if DEBUG`.
gmaclennan
enabled auto-merge
June 30, 2026 11:37
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.
Debug builds of a consuming app now symbolicate embedded-Node-backend errors in Sentry without uploading sourcemaps. The backend's
.mapships alongside the bundle and the native side passes Node's--enable-source-maps(underBuildConfig.DEBUG/#if DEBUG), so stacks are remapped to original positions in-process — devs no longer need a Sentry auth token or a per-build upload to read backend stack traces.Release builds are unchanged: maps stay out of the app and the consumer uploads them with
comapeo-rn-upload-sourcemaps(debug-ID matched, symbolicated server-side).Delivery uses each platform's native config split, so there's no custom build phase. Android colocates the debug map in the
src/debugasset tree (debug variants only). iOS adds a Debug-onlyComapeoCoreSourcemapscompanion pod via:configurations => ['Debug']; its maps merge next to the bundle in the.app(the CocoaPods resource copy runs without--delete), andapple.podspecPathis pinned so the companion is never autolinked into release.Verified end-to-end on
apps/integration: a clean iOS prebuild plus a Debugxcodebuildproduces an.appwhosenodejs-project/contains both the bundle and the merged maps, while the generated resources script installs the maps in the Debug configuration block only.