-
Notifications
You must be signed in to change notification settings - Fork 1
Description
This issue pertains to ads-github-cache, as shipped with ads-github-tools-0.3.5 (and all previous versions).
I encountered the following output on a run of the ads-github-cache program today (2026-03-04):
$ ads-github-cache --verbose --update -j 24
...
ads-github-cache (info): "paged collection" /user/repos: requesting page 22 of 23 (page size: 100)
ads-github-cache (info): "paged collection" /user/repos: requesting page 23 of 23 (page size: 100)
ads-github-cache (error): GET request for "/user/repos?page=6&per_page=100" failed; HTTP response code was: "502"; expected 200 ("OK"); bailing out
ads-github-cache (error): GET request for "/user/repos?page=17&per_page=100" failed; HTTP response code was: "502"; expected 200 ("OK"); bailing out
ads-github-cache (error): "paged collection" /user/repos: was error requesting page 6 of 23 (page size: 100)
ads-github-cache (error): "paged collection" /user/repos: was error requesting page 17 of 23 (page size: 100)
ads-github-cache (error): was error while emitting one or more pages for "paged collection" /user/reposNotice how we provide what RFC 9110 (in sections 6.2 and 15.1) calls the reason phrase ("OK") for the expected HTTP status code (200), but no reason phrase is provided for the actual status code (502).
In this particular case, it would have been nice to see the reason phrase "Bad Gateway" along with the 502 status code.
More generally, though, when something goes wrong, the more information we can provide, the better. Adding the reason phrase to the output would make it more complete and self-contained -- the user would not need to lookup the specific meaning of the code.
See also: