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

Remove @_retry decorator for _api_check #194

Open
mikemhenry opened this issue Oct 19, 2023 · 1 comment
Open

Remove @_retry decorator for _api_check #194

mikemhenry opened this issue Oct 19, 2023 · 1 comment
Labels
component-user-api enhancement New feature or request

Comments

@mikemhenry
Copy link
Collaborator

Since _api_check is in a private name space and isn't used except by unit tests + sys admins, I rather it just fail fast then keep trying. For example, I've got a deployment where I've got something misconfigured with S3, so when I call _api_check() I have to wait for the retry logic to run its course.

Other ideas:

  • allow _retry to accept kwargs/options so we could make the retry happen with a faster time out, but still try a few times before we just report the error code to the user
  • allow _api_check to take in an argument that disables retry logic
@mikemhenry mikemhenry added enhancement New feature or request component-user-api labels Oct 19, 2023
@dotsdl
Copy link
Member

dotsdl commented Oct 24, 2023

You can set the number of retries to 0 on the AlchemiscaleClient on init with max_retries=0. Also, could set after init with client.max_retries = 0.

Does that meet your needs?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component-user-api enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants