Skip to content

docs(react-native): Use scoped @sentry/cli in sourcemap upload examples#17426

Open
antonis wants to merge 1 commit intomasterfrom
antonis/rn-sentry-cli-scoped-npx
Open

docs(react-native): Use scoped @sentry/cli in sourcemap upload examples#17426
antonis wants to merge 1 commit intomasterfrom
antonis/rn-sentry-cli-scoped-npx

Conversation

@antonis
Copy link
Copy Markdown
Contributor

@antonis antonis commented Apr 21, 2026

DESCRIBE YOUR PR

Replaces every npx sentry-cli sourcemaps upload … invocation in the React Native source-map upload guides with npx @sentry/cli sourcemaps upload …. 5 occurrences across 2 files:

  • docs/platforms/react-native/sourcemaps/uploading/codepush.mdx (1)
  • docs/platforms/react-native/sourcemaps/uploading/expo-advanced.mdx (4)

IS YOUR CHANGE URGENT?

  • None: Not urgent, can wait up to 1 week+

Motivation

The unscoped sentry-cli name on npm is currently owned by a personal account (kamilogorek) that is no longer at Sentry. The package itself is a defensively crafted stub — no bin, and a postinstall that exits with "Use @sentry/cli instead" — so a user who runs npx sentry-cli … today without a local install gets a loud error rather than an exploit. That is the good case.

The residual risk is that the account sits outside Sentry's governance. If the credentials were ever compromised, an attacker could push a new version with a real bin and active payload, and anyone following the documented command (CI step without a prior npm install, copy-pasted shell, fresh environment) would execute it. Every npx sentry-cli … in the Sentry docs is a fall-through path into that account.

Routing the documented command through the @sentry/cli scoped name removes that fall-through entirely — @sentry is a locked npm scope that only Sentry members can publish to, so the transitive registry lookup can never reach a third-party-maintained package.

In-project behavior is unchanged: users with @sentry/cli installed locally already resolve the bin via ./node_modules/.bin/sentry-cli, so the scoped form is purely a safer spelling of the same invocation.

PRE-MERGE CHECKLIST

  • Checked Vercel preview for correctness, including links
  • PR was reviewed and approved by any necessary SMEs (subject matter experts)
  • PR was reviewed and approved by a member of the Sentry docs team

Follow-ups (not blocking this PR)

  • Reach out to the current sentry-cli npm maintainer and transfer package ownership to the Sentry npm org. One-time cleanup; permanently removes the account-compromise risk.
  • Audit the other Sentry SDK repos (sentry-javascript, sentry-java, etc.) for bare npx sentry-cli in their READMEs or examples. No other hits in sentry-docs itself (verified via grep).

The unscoped `sentry-cli` name on npm is held by a personal account that
is no longer under Sentry's governance. Route the documented commands
through the scope-locked `@sentry/cli` so the registry fallback path
cannot resolve to a third-party-maintained package.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@vercel
Copy link
Copy Markdown

vercel bot commented Apr 21, 2026

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

Project Deployment Actions Updated (UTC)
sentry-docs Ready Ready Preview, Comment Apr 21, 2026 1:55pm
1 Skipped Deployment
Project Deployment Actions Updated (UTC)
develop-docs Ignored Ignored Apr 21, 2026 1:55pm

Request Review

@codeowner-assignment codeowner-assignment bot requested a review from a team April 21, 2026 13:45
@antonis antonis marked this pull request as ready for review April 21, 2026 13:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant