Skip to content
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

Hotfix handle 429 timeout #14

Merged
merged 2 commits into from
Jun 15, 2021
Merged

Hotfix handle 429 timeout #14

merged 2 commits into from
Jun 15, 2021

Conversation

praskoson
Copy link
Owner

Implement a --retry-on-429 option for distributors when using transfer sub-command.

This was previously the default behaviour, but we learned that if spl-token transfer returns a HTTP Too Many Requests error (429), this is not a guarantee of a failed transaction. This is a bug in how spl-token handles those errors and according to Solana developer support, a fix is on the way.

A transaction happening despite this error is rare, but it can happen. The safe way to treat this error is to consider the transaction as unconfirmed, until the error is fixed in spl-token. The --retry-on-429 option will use the old behaviour, where the tool retried the transaction if it encountered this error.

Using config variables as globals makes it so we don't need to drill all of them as function arguments, instead we just use them where we need to. This should make it easier to modify in the future.
@praskoson praskoson added the bug Something isn't working label Jun 15, 2021
@praskoson praskoson self-assigned this Jun 15, 2021
@praskoson praskoson merged commit 2efd997 into main Jun 15, 2021
@praskoson praskoson deleted the hotfix-handle-429-timeout branch June 15, 2021 11:59
@praskoson praskoson linked an issue Jun 15, 2021 that may be closed by this pull request
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Issue when handling HTTP Too Many Requests (429) error
1 participant