Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Upload sourcemaps issue with latest 2.4.0 CLI release #1283

Closed
spra85 opened this issue Jul 13, 2022 · 5 comments · Fixed by #1284
Closed

Upload sourcemaps issue with latest 2.4.0 CLI release #1283

spra85 opened this issue Jul 13, 2022 · 5 comments · Fixed by #1284

Comments

@spra85
Copy link

spra85 commented Jul 13, 2022

Environment

How do you use Sentry?
Sentry SaaS (sentry.io)

Which SDK and version?

Javascript Sentry CLI, latest - 2.4.0

Steps to Reproduce

Basic command in our CI build is below, where REACT_APP_COMMIT is set to essentially Git SHA for release

sentry-cli releases files $REACT_APP_COMMIT upload-sourcemaps build/static/js

Our installation of Sentry-CLI used this command from the README:

curl -sL https://sentry.io/get-cli/ | bash

With the most recent version bump, the command above started failing with "release not found".

Pinning the version to the one right before does work, which implies a 2.4.0 change caused this.

curl -sL https://sentry.io/get-cli/ | SENTRY_CLI_VERSION=2.3.1 bash

It's possible we weren't correctly using it in the first place and 2.4.0 is more strict; for instance, from the docs it suggests this -

#!/bin/sh
sentry-cli releases new "$VERSION"
# do your build steps here
# once you are done, finalize
sentry-cli releases finalize "$VERSION"

With 2.4.0, does the CLI expect that we would first need to create a new release, prior to trying to upload the source map whereas previous versions allowed that to happen in a single step/command?

Expected Result

The source map would upload

Actual Result

[Container] 2022/07/13 14:56:32 Running command sentry-cli releases files $REACT_APP_COMMIT upload-sourcemaps build/static/js --validate --url-prefix '~/static/js'
--
error: release not found
@kamilogorek
Copy link
Contributor

Thanks for the report, should be fixed in #1284, will release a patched version once it's merged.

@spra85
Copy link
Author

spra85 commented Jul 13, 2022

Thanks @kamilogorek, once a patch is available we can retest. Obviously we have a workaround for now with pinning the version

@kamilogorek
Copy link
Contributor

With 2.4.0, does the CLI expect that we would first need to create a new release, prior to trying to upload the source map whereas previous versions allowed that to happen in a single step/command?

It should do that from the very beginning, but it somehow snuck into the upload behavior and stayed that way forever. My feature addition did not intend to change that, so I'll fix that :)

@joer14
Copy link

joer14 commented Jul 13, 2022

Yah this issue blocked a release for us and helped uncover an unpinned dependency. Thanks for reporting @spra85!!!

@kamilogorek
Copy link
Contributor

The issue should be fixed in 2.4.1.

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 a pull request may close this issue.

3 participants