Fix #454: Report failed HLR lookup sources instead of silently ignoring - #455
marioalbu08 wants to merge 3 commits into
Conversation
|
Thanks for the first pull request here. CI needs a maintainer to approve the run before it starts, so it may sit for a bit before anything happens. |
|
Thanks, this works: every source now ends up in either
if result["sources_failed"] and not result["sources"]:and the counter can go. Also, for next time: comment on the issue before you start. You have done good work on several of these, and a comment is how the next person knows it is taken. |
95dc412 to
dc67aa9
Compare
Summary
Resolves #454 by tracking network timeouts and HTTP errors from reverse lookup sources and appending them to a new
sources_failedarray.Changes
HLRLookup.reverse_lookupinmodules/hlr_lookup.pyto capturerequests.gettimeouts and non-200 status codes.total_sources_attemptedcounter. If the length ofsources_failedmatches the total attempted sources, the result is now properly annotated as anERRORusingmodule_status.annotate.test_reverse_lookup_partial_failureandtest_reverse_lookup_all_failedtotests/test_modules_extended.pyusingmonkeypatchto simulate 500/404/Timeouts and verify the new arrays.Type of change
Testing