Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 11 additions & 2 deletions skills/sentry-react-native-sdk/SKILL.md
Original file line number Diff line number Diff line change
Expand Up @@ -658,14 +658,23 @@ Sentry.init({
| `SENTRY_AUTH_TOKEN` | Upload source maps and dSYMs | **Never commit — use CI secrets** |
| `SENTRY_ORG` | Organization slug | Used by wizard and build plugins |
| `SENTRY_PROJECT` | Project slug | Used by wizard and build plugins |
| `SENTRY_RELEASE` | Release identifier | Falls back from `release` option |
| `SENTRY_DIST` | Distribution identifier | Falls back from `dist` option |
| `SENTRY_RELEASE` | Release identifier (e.g., `myapp@1.2.3+42`) | Read at build time by the Sentry Metro plugin / Expo config plugin; overrides code-level `release` config |
| `SENTRY_DIST` | Distribution identifier (e.g., build number or commit SHA) | Read at build time by the Sentry Metro plugin / Expo config plugin; overrides code-level `dist` config |
| `SENTRY_ENVIRONMENT` | Environment name | Falls back from `environment` option |
| `SENTRY_DISABLE_AUTO_UPLOAD` | Skip source map upload | Set `true` during local builds |
| `EXPO_PUBLIC_SENTRY_DSN` | Expo public env var for DSN | Safe to embed in client bundle |
| `SENTRY_EAS_BUILD_CAPTURE_SUCCESS` | EAS build hook: capture successful builds | Set `true` in EAS secrets |
| `SENTRY_EAS_BUILD_TAGS` | EAS build hook: additional tags JSON | e.g., `{"team":"mobile"}` |

Example (`.env` or CI environment):

```bash
SENTRY_RELEASE=com.myapp@1.2.3+42
SENTRY_DIST=42
```

`SENTRY_RELEASE` and `SENTRY_DIST` are read during the native build. They do not need to be bundled into the app at runtime.
Comment on lines +674 to +676
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Bug: The documentation for SENTRY_RELEASE and SENTRY_DIST is contradictory, stating they are only for native build time while also being listed as runtime SDK initialization options.
Severity: MEDIUM

Suggested Fix

Revert the new documentation to align with the previous version and other Sentry SDKs. The text should clarify that SENTRY_RELEASE and SENTRY_DIST are used as fallbacks for the options.release and options.dist SDK initialization options, and must be available during the Metro bundling process to be included in the final app bundle.

Prompt for AI Agent
Review the code at the location below. A potential bug has been identified by an AI
agent. Verify if this is a real issue. If it is, propose a fix; if not, explain why it's
not valid.

Location: skills/sentry-react-native-sdk/SKILL.md#L674-L676

Potential issue: The documentation added at lines 661-676 incorrectly states that the
`SENTRY_RELEASE` and `SENTRY_DIST` environment variables are only used at native build
time and "do not need to be bundled into the app at runtime." This contradicts other
sections of the same document (lines 554-555) and the official Sentry React Native
documentation, which clarify these are read automatically during SDK initialization.
This misleading guidance will cause AI models to advise developers against setting these
variables during the bundling process, resulting in Sentry events missing release and
distribution information, which will break source map processing.

Did we get this right? 👍 / 👎 to inform future reviews.


---

## Source Maps & Debug Symbols
Expand Down