Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

HTTP errors are not handled and result in cache poisoning #50

Open
@tdltdl

Description

In BaseRequest, the only response code handled is 429 (Rate Limit).

Any other code are just ignored and an empty result is returned. If a cache defined, it will poisoning it with an empty value.

If the token is incorrect (or the service has not been renewed on time) will result in silent errors. Same if your service has a glitch and return 5xx error.

As I expect the service would always return 200 in case of success (I assume it will not return 302 or any partial response), any non 200 code could return null and not be stored in the cache.

"Expected" errors like 403 could raise their own exception - probably same for 5xx. I would also add some logging in there.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions

        AltStyle によって変換されたページ (->オリジナル) /