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

improve string representation of timeout errors #3118

Merged
merged 1 commit into from
Apr 2, 2021

Conversation

marten-seemann
Copy link
Member

Currently, an idle timeout's string representation is NO_ERROR: No recent network activity. With this PR, it will be Timeout: No recent network activity.

Note that this will break some applications building on top of quic-go that are performing string matching to detect timeout errors. I don't see this as a problem with this PR though, I regard this as a feature.
While it is true that our errors are not as helpful as they could be (see #2441), detecting timeout errors is not a problem: Our errors implement the net.Error interface, which defines a Timeout() bool method.

@codecov
Copy link

codecov bot commented Mar 23, 2021

Codecov Report

Merging #3118 (afbb2b7) into master (81d16a9) will increase coverage by 0.01%.
The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #3118      +/-   ##
==========================================
+ Coverage   85.47%   85.48%   +0.01%     
==========================================
  Files         131      131              
  Lines        9650     9654       +4     
==========================================
+ Hits         8248     8252       +4     
  Misses       1034     1034              
  Partials      368      368              
Impacted Files Coverage Δ
internal/qerr/quic_error.go 97.73% <100.00%> (+0.23%) ⬆️

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 81d16a9...afbb2b7. Read the comment docs.

@marten-seemann marten-seemann merged commit bd2dfd5 into master Apr 2, 2021
@marten-seemann marten-seemann deleted the improve-timeout-error-string branch April 2, 2021 10:29
@aschmahmann aschmahmann mentioned this pull request May 14, 2021
71 tasks
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.

2 participants