Uh oh!
There was an error while loading. Please reload this page.
Implement new QuicException proposal - #71432
Conversation
ghost
commented
Jun 29, 2022
Note regarding the This serves as a reminder for when your PR is modifying a ref *.cs file and adding/modifying public APIs, to please make sure the API implementation in the src *.cs file is documented with triple slash comments, so the PR reviewers can sign off that change. |
ghost
commented
Jun 29, 2022
Tagging subscribers to this area: @dotnet/ncl Issue DetailsCloses #70669.
|
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
ManickaP
left a comment
There was a problem hiding this comment.
Looks good modulo comments, thanks!![]()
| // Licensed to the .NET Foundation under one or more agreements. | ||
| // The .NET Foundation licenses this file to you under the MIT license. | ||
| using Microsoft.Quic; |
There was a problem hiding this comment.
Looks good, could you just move the file to System/Net/Quic/Internal so it doesn't wreak complete havoc on my PRs 😄
| namespace System.Net.Quic | ||
| { | ||
| public class QuicException : Exception | ||
| public sealed class QuicException : IOException |
There was a problem hiding this comment.
This will need XML comments as well since we generate docs from them.
| HttpRequestException ex = await Assert.ThrowsAsync<HttpRequestException>(() => client.SendAsync(request).WaitAsync(TimeSpan.FromSeconds(10))); | ||
| Assert.Contains("ALPN_NEG_FAILURE", ex.Message); | ||
| AuthenticationException authEx = Assert.IsType<AuthenticationException>(ex.InnerException); | ||
| Assert.Contains("Application layer protocol negotiation", authEx.Message); |
There was a problem hiding this comment.
Just wonder, is it ok to check like that? what if exception message gets localized?
There was a problem hiding this comment.
I don't know of any other way to check for this specific type of error, so the alternative is to check just for the exception type.
I think I have seen some other test elsewhere that depends on the English localization of the exception messages, but I am not sure where.
There was a problem hiding this comment.
I checked and there is precious few of such cases in runtime sources (e.g. https://github.com/dotnet/runtime/blob/70669-QuicException/src/libraries/System.Text.Json/tests/System.Text.Json.Tests/Serialization/ExceptionTests.cs#L495).
So I will remove the assert
What's the plan about the adaption of |
rzikm
commented
Jul 12, 2022
Good catch, I will put up a follow-up tomorrow |
Closes#70669.