-
Notifications
You must be signed in to change notification settings - Fork 700
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
Do not post fault telemetry for cancellation exceptions #6139
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
dtivel
previously approved these changes
Nov 7, 2024
donnie-msft
reviewed
Nov 7, 2024
src/NuGet.Clients/NuGet.PackageManagement.UI/ViewModels/PackageItemViewModel.cs
Outdated
Show resolved
Hide resolved
zivkan
reviewed
Nov 7, 2024
src/NuGet.Core/NuGet.Protocol/Providers/ServiceIndexResourceV3Provider.cs
Outdated
Show resolved
Hide resolved
zivkan
reviewed
Nov 7, 2024
src/NuGet.Core/NuGet.Protocol/Providers/ServiceIndexResourceV3Provider.cs
Outdated
Show resolved
Hide resolved
176ebae
to
614d7ce
Compare
donnie-msft
approved these changes
Nov 14, 2024
dtivel
approved these changes
Nov 14, 2024
nkolev92
approved these changes
Nov 14, 2024
zivkan
approved these changes
Nov 18, 2024
src/NuGet.Clients/NuGet.VisualStudio.Common/Telemetry/TelemetryUtility.cs
Show resolved
Hide resolved
Nigusu-Allehu
approved these changes
Nov 18, 2024
614d7ce
to
1f39805
Compare
I had to rebase, re-requesting reviews... |
Nigusu-Allehu
approved these changes
Dec 2, 2024
zivkan
approved these changes
Dec 2, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Bug
Fixes: https://github.com/NuGet/Client.Engineering/issues/3013
Description
Our code is posting fault telemetry for cancellations and it should not be. The
PackageItemViewModel
was assuming that HTTP timeouts were throwing aTaskCanceledException
but that is not the case. InTimeoutUtility
we detect a timeout and throw aTimeoutException
instead:NuGet.Client/src/NuGet.Core/NuGet.Protocol/Utility/TimeoutUtility.cs
Line 46 in 3872959
This change updates the view model based on my findings and blocks any
OperationCancelledException
from posting telemetry. Any code in the future where we want to post fault telemetry but its not really a cancellation should wrap the exception as something else like aTimeoutException
.PR Checklist