-
-
Notifications
You must be signed in to change notification settings - Fork 227
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
Releases and Sourcemaps of different projects get mixed up #482
Comments
This is expected behavior. Releases are tied to the organization and not a single project. So when naming releases with their version number, I would suggest to prefix it with either some bundle identifier or the project name. Example |
Thanks for the fast response. Can you tell me what is the idea behind this behaviour? |
The original idea behind this design was to allow synchronizing releases across multiple projects. The source maps associated to that release would then automatically be used by all project, for instance. |
Am I correct that only the sourcemaps are shared by releases with the same name or is the release itself is also shared? |
Question: I have two projects A(Website) and B(Cordova mobile app). Both projects have same files. Right now I am first uploading my JS/Sourcemap files first to Project A and then I am uploading same files to Project B. Do I really need to do it twice? Or Uploading JS/source-maps to Project A will be shared with Project B also. Release keys are the same for both projects and are under the same organization. |
@jan-auer It's really strange behavior. We are using the following commands: SENTRY_PROJECT=$APP_NAME-$APP_ROLE // eg. iam-server-corp, iam-server-public
SENTRY_RELEASE=$APP_NAME-$APP_REVISION // eg. iam-server-191218-ce44919b
echo -e "Sending sourcemaps for SENTRY_PROJECT: ${YELLOW}$SENTRY_PROJECT${NC}"
sentry-cli releases -p $SENTRY_PROJECT new $SENTRY_RELEASE || true
sentry-cli releases -p $SENTRY_PROJECT set-commits $SENTRY_RELEASE --auto || true
sentry-cli releases -p $SENTRY_PROJECT files $SENTRY_RELEASE upload-sourcemaps --rewrite . || true
sentry-cli releases -p $SENTRY_PROJECT deploys $SENTRY_RELEASE new -e $APP_ENV || true According to these cli commands - it's very strange that we use Global releases blow my mind 🤯, cause any sentry account may contain different projects with the same app versioning strategy (eg. 1.0.0, 1.0.1 etc.). And now I'm forced to add prefixes to all my releases and also provide app prefix with every error. And every record error now contains the long ugly release strings (something like It's better to store short revision ids in DB for performance reasons. And have double or more copies of source-maps for every project. |
Closing the issue, as it seems like the original issue has been partially resolved or there is a working solution. I'd prefer someone to create a new issue with a fresh description if it's still an issue. |
In what scenarios could we have 2 different projects tracking the same release and the same sourcemaps? Just trying to understand if the files are in the releases are the same, in what scenarios would we need multiple projects ? |
@gaurav5430 kinda. Releases are "buckets" for multiple projects. So you can have a release "MangoJalapeno" which includes multiple projects like "Frontend", "Backend", "Database" and so on, so forth. All release files are available for every project within it. However, if you want to release let's say "frontend" to multiple instances, eg. |
But in what scenarios do you need to have access to frontend release files in the backend release project? I am trying to understand why this decision was taken? |
fixes that sentry releases are associated with an organization instead a project. For more information about this topic read: getsentry/sentry-cli#482
I noticed that when you have two project and both project have a release with the same name, the sourcemaps appear in both project releases after uploading them to one of them.
Meta
Repro
project-1
,project-2
SENTRY_AUTH_TOKEN
,SENTRY_PROJECT
,SENTRY_ORG
,SENTRY_URL
sentry-cli.exe releases new 0.0.0.1
sentry-cli.exe releases files 0.0.0.1 upload-sourcemaps --ext js --ext map ./sourcemaps/ --validate --no-rewrite --url-prefix ~/
--url-prefix ~/test
Result
project-1
andproject-2
contain a release called0.0.0.1
with the artifacts~/sourcemap.js.map
AND~/test/sourcemap.js.map
Expected
project-1
andproject-2
contain a release called0.0.0.1
.project-1
contains the artifact~/sourcemap.js.map
andproject-2
contains the artifact~/test/sourcemap.js.map
The text was updated successfully, but these errors were encountered: