Skip to content

Experiencing 401 Bad Credentials when credentials are valid #243

@dlouseiro

Description

@dlouseiro

While synchronising data for our github organisation, we've been experiencing consistent HTTP 401 errors with the reason "Bad credentials" which should occur when an invalid token is provided.

Although, this happens after a lot of time into the synchronisation, after performing multiple successful API calls with the same credentials. According to this line of code a similar behaviour has been experienced (random 401 errors - triggering a retry), but not with the reason "Bad Credentials".

All failures experienced were while fetching team members stream, but always in different teams/members. Not consistently on the exact same call.

While trying a curl call to this endpoint using the same token and endpoint call that cause the failure, we receive a 200 OK.

Yet another detail which makes the behaviour even weirder is that if I do an execution with --select teammembers.*, the execution is successful without any failure. With the exact same token.

While an easy solution could be to changethis line of code to retry on any 401 call (not excluding bad credentials), this would cause the tap to retry, even when a bad token is effectively provided.

So, the only solution I see would be to retry on every 401 call, as long as an X amount of API calls was already successfully performed with the same credentials.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    Status

    No status

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions