Open
Description
CLI Version
2.42.2 2.37.0
Operating System and Architecture
- macOS (arm64)macOS (x86_64)Linux (i686)Linux (x86_64)Linux (armv7)Linux (aarch64)Windows (i686)Windows (x86_64)
Operating System Version
15.3.1 (24D70)
Link to reproduction repository
No response
CLI Command
sentry-cli sourcemaps upload --org ORG_B --project PROJ_B ./dist
Exact Reproduction Steps
- Login to
ORG_A
using thesentry-cli
- Use the wizard to set up sourcemaps for a project. In the process, login to
ORG_B
- Confirm that a
SENTRY_AUTH_TOKEN
was created for that org (ORG_B
) and saved to.env.sentry-build-plugin
. (either useb64decode
or look for that token in the org development settings) - Try to upload sourcemaps using
sentry-cli sourcemaps upload --org ORG_B --project PROJ_B ./dist
.
Expected Results
I expect the sentry-cli
to use the token contained within the project (in the .env.sentry-build-plugin
) or a way to directly specify the token contained.
Actual Results
It seems the sentry-cli
uses the global token.
Logs
WARN 2025-03-20 11:22:51.574001 +01:00 Using organization `ORG_A` (embedded in token) rather than manually-configured organization `ORG_B`. To use `ORG_B`, please provide an auth token for this organization.
> Found 4 files
> Analyzing 4 sources
> Analyzing completed in 0.002s
> Rewriting sources
> Rewriting completed in 0.016s
> Adding source map references
> Bundling completed in 0.045s
> Bundled 4 files for upload
> Bundle ID: ...
> Optimizing completed in 0.001s
error: API request failed
Caused by:
sentry reported an error: One or more projects are invalid (http status: 400)
Metadata
Metadata
Assignees
Labels
No labels
Type
Projects
Milestone
Relationships
Development
No branches or pull requests
Activity