-
-
Notifications
You must be signed in to change notification settings - Fork 222
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
Sourcemaps upload with --url-prefix behavior is strange #1605
Comments
What's happening here I believe is that we are deduplicating files based on their content hash. If you want to have multiple files with exactly same content, use If that still doesnt work, please provide debug logs with either |
@kamilogorek thanks for the response, however I still do not understand few things:
Maybe you have any thoughts on that behavior? |
It seems, that I found out the issue with debug mode, in logs I spotted that it fetches the artifacts from release:
As you can see, the url is very long, and maybe because of this this request fails with 502 error and thus services with 30+ artifacts are working good. As I understand, Sentry makes a request to get a files with checksum for comparison and in this case comparison is failed and it uploads artifacts again. On the other side, when we have a small amount of artifacts, that request is not so long and it handles correctly, returning the list of existing artifacts. Thus it compares to the uploading source maps and skip it. |
And one more question: we use @sentry/cli npm package and call that Sentry stuff in typescript code. I actually do not see possibility to use this --no-dedupe flag in that module. You can check typings here: https://github.com/getsentry/sentry-cli/blob/master/js/index.d.ts#LL66C4-L66C4 |
Ah, you're right, updated in the PR.
You're totally right. We've been bitten by this few times already, and we want to change this check in the future to not use query params, but rather pass this data in the body instead.
This is changing now, as we're moving to debugIds instead of relying on fragile urls; You can read about them here - https://sentry.engineering/blog/the-case-for-debug-ids |
Thank you! After you merge the PR and create a new release I will give it a shot and hopefully the issue will be resolved |
Seems working, thanks a lot for quick reaction! |
Environment
We have sentry on-premise version 22.5.0
nodejs version 16
sentry-cli version 2.17.5
Steps to Reproduce
As part of releasing frontend applications, we create Sentry release, set commits, upload source maps and create deployment. The problem is that we have different environment and different CDN for stagings / preprod / prod.
When source maps uploaded first time to release, everything works good. Let's say, I deploy my code on stg25 , source maps are uploaded using the following command:
sentry-cli releases -o myOrg -p appjs-sdk files 1e2e77d8 upload-sourcemaps ./dist --url-prefix '~/stg25/appjs-sdk'
If I open appjs-sdk project in Sentry, then go to source maps configuration and select release 1e2e77d8 I will find source files together with source maps. Their names look like:
~/stg25/appjs-sdk/bootstrap-4b2cd0de.js
, which is expected for me.If after that, I decided to deploy this to preprod, source maps are uploaded using the following command:
sentry-cli releases -o myOrg -p appjs-sdk files 1e2e77d8 upload-sourcemaps ./dist --url-prefix '~/preprod/appjs-sdk'
If I open appjs-sdk project in Sentry, then go to source maps configuration and select release 1e2e77d8 I will not find sources and files with names
~/preprod/appjs-sdk/bootstrap-4b2cd0de.js
which is unexpected for me. Even in Sentry tutorial video https://youtu.be/hEwpjRHRpC8?t=593 source maps are uploaded with different--url-prefix
and they become visible on UI.The problem is that we have a production issue in Sentry, and source maps are not applied to it.
Moreover, I see that some of our releases contain source maps and sources for many staging, preprod and prod, so it seems that the issue if flaky.
Expected Result
Uploading source maps with different
--url-prefix
results in showing them on UI under the release artifact and will apply to Sentry issues.Actual Result
Uploading source maps with different
--url-prefix
seems has no effect after first source maps were uploaded with any--url-prefix
The text was updated successfully, but these errors were encountered: