-
Notifications
You must be signed in to change notification settings - Fork 183
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
Change logs to use current_exceptions_to_string()
instead of exception=
pattern
#1092
Conversation
I'm seeing Test threw exception
Expression: close(server)
UndefVarError: current_exceptions not defined
Stacktrace:
[1] current_exceptions_to_string()
@ HTTP.Exceptions ~/work/HTTP.jl/HTTP.jl/src/Exceptions.jl:103
[2] shutdown(fn::Main.test_server.var"#shutdown_throw#24")
@ HTTP.Servers ~/work/HTTP.jl/HTTP.jl/src/Servers.jl:196
[3] foreach(f::typeof(HTTP.Servers.shutdown), itr::Vector{Function})
@ Base ./abstractarray.jl:2141 in the 1.6 tests |
Aha, yeah, thanks! 👍 |
Some tests are not being run... is that intentional? I couldn't see an issue about it so i opened one: #1093 |
Yes, intentional. Thanks for opening the issue as I forgot about it. The downloads tests were relying on a public server that is no longer serving requests in the same way, so they were just constantly failing, so they were disabled. I pinged @oxinabox about it, but I think it's kind of a pain to dig into and figure out what to do instead. |
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.
Friendly ping. Can we review and merge this soon? This was making it harder to debug the AT&T incident we encountered, and I'd like to close the repair item.
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.
Oh, whoops, i didn't realize the test were failing. I pushed up a change that will hopefully fix it. :)
Looks like Autobahn Server tests are failing (it seems these tests only run on linux) Server: Test Failed at /home/runner/work/HTTP.jl/HTTP.jl/test/websockets/autobahn.jl:90
Expression: v["behavior"] in ("OK", "NON-STRICT", "INFORMATIONAL", "UNIMPLEMENTED")
Evaluated: "FAILED" in ("OK", "NON-STRICT", "INFORMATIONAL", "UNIMPLEMENTED")
Stacktrace:
[1] macro expansion
@ /opt/hostedtoolcache/julia/1.9.3/x64/share/julia/stdlib/v1.9/Test/src/Test.jl:478 [inlined]
[2] macro expansion
@ ~/work/HTTP.jl/HTTP.jl/test/websockets/autobahn.jl:90 [inlined]
[3] macro expansion
@ /opt/hostedtoolcache/julia/1.9.3/x64/share/julia/stdlib/v1.9/Test/src/Test.jl:1498 [inlined]
[4] macro expansion
@ ~/work/HTTP.jl/HTTP.jl/test/websockets/autobahn.jl:80 [inlined]
[5] macro expansion
@ /opt/hostedtoolcache/julia/1.9.3/x64/share/julia/stdlib/v1.9/Test/src/Test.jl:1498 [inlined]
[6] top-level scope
@ ~/work/HTTP.jl/HTTP.jl/test/websockets/autobahn.jl:22 |
2f950b6
to
45b6d92
Compare
Slightly related to this PR, there is a bad call to HTTP.jl/src/clientlayers/ConnectionRequest.jl Line 134 in 45b6d92
|
Thanks, i've fixed that. ... So we're missing code coverage on that error path, yeah? |
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #1092 +/- ##
==========================================
+ Coverage 82.49% 82.67% +0.18%
==========================================
Files 32 32
Lines 3044 3053 +9
==========================================
+ Hits 2511 2524 +13
+ Misses 533 529 -4 ☔ View full report in Codecov by Sentry. |
Introducing codecov is the right answer:) |
The remaining test failures are also flakes from tests that I introduced very recently #1110. There I test that internal exceptions are not retried by expecting the request to finish way sooner than the total retry delays, but now I think I didn't choose good value for that (max waiting time of 3 seconds was perhaps too ambitious). Sorry for that! I think if we bump the total delay and max waiting time by 10x, it should be less flakey. |
Signoff from @Drvi on slack that we can ignore the Invalidations job failure for now. Thanks! |
…tion=` pattern (#1092) * Change logs to use `current_exceptions_to_string()` instead of `exception=` * cleanup unused variable `catch e` * Update Exceptions.jl for older julia * Rename err => msg; fix missing import * Make "Don't retry on internal exceptions" less flakey --------- Co-authored-by: Nick Robinson <[email protected]> Co-authored-by: Tomáš Drvoštěp <[email protected]>
…tead of `exception=` pattern (#1115) * Change logs to use `current_exceptions_to_string()` instead of `exception=` pattern (#1092) * Change logs to use `current_exceptions_to_string()` instead of `exception=` * cleanup unused variable `catch e` * Update Exceptions.jl for older julia * Rename err => msg; fix missing import * Make "Don't retry on internal exceptions" less flakey --------- Co-authored-by: Nick Robinson <[email protected]> Co-authored-by: Tomáš Drvoštěp <[email protected]> * Bump release to v1.9.16 for #1092 --------- Co-authored-by: Nick Robinson <[email protected]> Co-authored-by: Tomáš Drvoštěp <[email protected]>
This is a follow-up from #1065, fixing a few more cases of the old logging style.
Also adds a test that at least one of those logs does indeed log the exception details in the string, so we know the exception logging is working as expected.
Finally, cleans up a couple unused variables in
catch e
in 2 places, and updatesBase.catch_stack()
toBase. current_exceptions()
, which is the new, public API for this which is exported from Base. It starts warning about calling the older, deprecated function in 1.9.