You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Oct 23, 2026. It is now read-only.
Repository navigation
This repository was archived by the owner on Oct 23, 2026. It is now read-only.
sourcemap inject requires authentication even though it never calls the API #1525
Thank you for maintaining the CLI. sentry sourcemap inject <dir> exits with Not authenticated. Run 'sentry auth login' first. when no credentials are present, although it only rewrites local JS and .map files and never calls the Sentry API. It worked without a token up to 0.22.0. This blocks build steps that inject Debug IDs without a token and leave sourcemap upload to a separate, credentialed job.
I searched open and closed issues and PRs (inject, debug id, Not authenticated) and did not find an existing report.
Environment
sentry 0.44.1 (npm), Node.js 26.8.1, macOS arm64; also reproduced on GitHub Actions ubuntu-24.04.
Error: Not authenticated. Run 'sentry auth login' first.
Exit code 10, no file modified. 0.21.0 and 0.22.0 inject successfully; 0.23.0 through 0.44.1 fail. sentry sourcemap resolve . succeeds under the same conditions.
Expected behavior
sourcemap inject runs without credentials, like sourcemap resolve. sourcemap upload should keep requiring authentication.
Potential commit/PR that introduced the regression
#611 (0d322393, released in 0.23.0) made authentication the default for every buildCommand and opted out auth *, help, schema, and cli *, but not the sourcemap commands added a week earlier in #547. On current main:
Workaround: export any non-empty SENTRY_AUTH_TOKEN for the inject step; the guard only checks that a token exists. This report is only about the guard on sourcemap inject, not the auth-by-default policy. I have a small fix with a regression test ready and will open a PR referencing this issue. Please let me know if the current behavior is intended.
Activity
BYK commentedon Sep 2, 2026
Jared, we already have a PR so you can ignore this