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

Prevent duplicate package reporting #1197

Merged
merged 8 commits into from
Sep 20, 2021

Conversation

josh-degraw
Copy link
Contributor

Fixes #1195

Copy link
Member

@bruno-garcia bruno-garcia left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@bruno-garcia
Copy link
Member

D:\a\sentry-dotnet\sentry-dotnet\src\Sentry\Package.cs(63,29): error CS1591: Missing XML comment for publicly visible type or member 'Package.GetHashCode()' [D:\a\sentry-dotnet\sentry-dotnet\src\Sentry\Sentry.csproj]

Little gotcha: we only warn missing XML docs on Release builds, so we can dev in peace in Debug mode and only clean that up before the final push. ./build.sh does that check if u want to do a test before pushing

@lucas-zimerman
Copy link
Collaborator

Since Danger doesn't show the message here for PRs outisde of the main fork.

Please consider adding a changelog entry for the next release.

Instructions and example for changelog
Please add an entry to `CHANGELOG.md` to the "Unreleased" section. Make sure the entry includes this PR's number.

Example:
Prevent duplicate package reporting ([#1197](https://github.com/getsentry/sentry-dotnet/pull/1197))
If none of the above apply, you can opt-out of this check by adding `#skip-changelog` to the PR description.

@bruno-garcia
Copy link
Member

Since Danger doesn't show the message here for PRs outisde of the main fork.

Please consider adding a changelog entry for the next release.

Instructions and example for changelog
Please add an entry to `CHANGELOG.md` to the "Unreleased" section. Make sure the entry includes this PR's number.

Example:
Prevent duplicate package reporting ([#1197](https://github.com/getsentry/sentry-dotnet/pull/1197))
If none of the above apply, you can opt-out of this check by adding `#skip-changelog` to the PR description.

You have write access to the repo, you can change your remote to this and remove ur fork

@lucas-zimerman
Copy link
Collaborator

Test failed

  Sentry.Log4Net.Tests -> /Users/runner/work/sentry-dotnet/sentry-dotnet/test/Sentry.Log4Net.Tests/bin/Release/netcoreapp2.1/Sentry.Log4Net.Tests.dll
  Sentry.AspNetCore.Grpc.Tests -> /Users/runner/work/sentry-dotnet/sentry-dotnet/test/Sentry.AspNetCore.Grpc.Tests/bin/Release/netcoreapp3.1/Sentry.AspNetCore.Grpc.Tests.dll
  Sentry.EntityFramework.Tests -> /Users/runner/work/sentry-dotnet/sentry-dotnet/test/Sentry.EntityFramework.Tests/bin/Release/netcoreapp3.1/Sentry.EntityFramework.Tests.dll
[xUnit.net 00:00:24.40]     Sentry.Tests.Protocol.SdkVersionTests.SerializeObject_IgnoresDuplicatePackages [FAIL]
Error: Sentry.Tests.Protocol.SdkVersionTests.SerializeObject_IgnoresDuplicatePackages: Assert.Equal() Failure
  Failed Sentry.Tests.Protocol.SdkVersionTests.SerializeObject_IgnoresDuplicatePackages [< 1 ms]
  Error Message:
   Assert.Equal() Failure
                                 ↓ (pos 34)
Expected: ···"name":"nuget:Sentry.Extensions.Logging","version":"3.9.2"},{···
Actual:   ···"name":"nuget:Sentry","version":"3.9.2"},{"name":"nuget:Sentr···
                                 ↑ (pos 34)
  Stack Trace:
     at Sentry.Tests.Protocol.SdkVersionTests.SerializeObject_IgnoresDuplicatePackages() in /Users/runner/work/sentry-dotnet/sentry-dotnet/test/Sentry.Tests/Protocol/SdkVersionTests.cs:line 74
Test run for /Users/runner/work/sentry-dotnet/sentry-dotnet/test/Sentry.EntityFramework.Tests/bin/Release/netcoreapp3.1/Sentry.EntityFramework.Tests.dll (.NETCoreApp,Version=v3.1)
Microsoft (R) Test Execution Command Line Tool Version 16.11.0
Copyright (c) Microsoft Corporation.  All rights reserved.

Copy link
Collaborator

@lucas-zimerman lucas-zimerman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Other than the mentioned topics, it looks ok for me.

@codecov-commenter
Copy link

codecov-commenter commented Sep 17, 2021

Codecov Report

Merging #1197 (6ce5dfd) into main (05ac5e6) will increase coverage by 0.01%.
The diff coverage is 28.57%.

Impacted file tree graph

@@            Coverage Diff             @@
##             main    #1197      +/-   ##
==========================================
+ Coverage   80.44%   80.45%   +0.01%     
==========================================
  Files         212      212              
  Lines        6902     6908       +6     
  Branches     1579     1582       +3     
==========================================
+ Hits         5552     5558       +6     
- Misses        822      824       +2     
+ Partials      528      526       -2     
Impacted Files Coverage Δ
src/Sentry/Package.cs 75.00% <16.66%> (-25.00%) ⬇️
src/Sentry/SdkVersion.cs 100.00% <100.00%> (ø)
...rc/Sentry/Extensibility/SentryStackTraceFactory.cs 89.24% <0.00%> (+1.07%) ⬆️
src/Sentry/Internal/MainSentryEventProcessor.cs 89.85% <0.00%> (+1.44%) ⬆️
src/Sentry/SentryClient.cs 78.86% <0.00%> (+1.62%) ⬆️
src/Sentry/Internal/MainExceptionProcessor.cs 95.08% <0.00%> (+1.63%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 05ac5e6...6ce5dfd. Read the comment docs.

CHANGELOG.md Outdated
@@ -1,6 +1,7 @@
# Changelog

## Unreleased
- Prevent duplicate package reporting ([#1197](https://github.com/getsentry/sentry-dotnet/pull/1197))
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ideally this goes under the ### Fixes

Copy link
Member

@bruno-garcia bruno-garcia left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Small adjustment on the changelog but other than that feel free to merge

@bruno-garcia bruno-garcia merged commit 82e07c1 into getsentry:main Sep 20, 2021
@bruno-garcia
Copy link
Member

@josh-degraw feel free to merge ur own PRs once they are approved

@josh-degraw josh-degraw deleted the duplicate-packages branch September 20, 2021 19:51
@josh-degraw
Copy link
Contributor Author

@josh-degraw feel free to merge ur own PRs once they are approved

Sounds good, I was actually just about to ask you that haha.

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 this pull request may close these issues.

Avoid adding SDK info twice to event
4 participants