-
-
Notifications
You must be signed in to change notification settings - Fork 211
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
Improvements for Sentry CLI integration #2145
Conversation
We're getting build failures when I can repro locally as well. The error is:
Adding |
Note, it doesn't seem to happen for The error is on that one project/target, and only goes away if I don't pass |
That is very weird. So we get an embedded source for a |
Already on it |
Reproduced locally: fails on
While it's likely this won't be needed, I'll try to get this resolved properly in symbolic, thus getting it fixed in CLI, symbolicator & sentry.io Though I wonder if that might be a bug in the dotnet SDK when producing the ppdb, considering the specification says it should be "Document" when we filter "Embedded Source"... On a side note, when do we even upload all the intermediate stuff from |
It's likely a bug... I tried to fetch the Document from the MethodDebugInformation table by the given MethodDef value but it's out of bounds because all indexing in PPDB is 1-based... and the value is zero... I'll just make the change to skip these gracefully |
Given that we don't want a Sentry CLI upload failure to fail the build, I've changed it to log a warning instead. I've also added code to retry with sources disabled, so we still get symbols. This should be good enough until the next release of Symbolic+SentryCLI with the issue fixed. |
I originally chose |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
<Target Name="UploadSymbolsToSentry" AfterTargets="Build;Publish" DependsOnTargets="PrepareSentryCLI" Condition="'$(SentryUploadSymbols)' == 'true' And '$(SentryCLI)' != ''"> | ||
|
||
<Warning Condition="'$(SentryUploadSources)' == 'true' And '$(EmbedAllSources)' == 'true'" | ||
Text="Both SentryUploadSources and EmbedAllSources are enabled. Disabling SentryUploadSources." /> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nit:
Text="Both SentryUploadSources and EmbedAllSources are enabled. Disabling SentryUploadSources." /> | |
Text="Both SentryUploadSources and EmbedAllSources are enabled. Ignoring SentryUploadSources." /> |
SentryUploadSources
msbuild property. Settrue
to opt-in to uploading sources while uploading symbols. See Support for Source Context #646 (comment)bin
folder by default, and adds aSentryIncludeIntermediateOutputPath
property which can be settrue
to also include theobj
folder.SentryUploadSources
is enabled, it will retry with symbols only (no sources).