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

Requests timeout fix #190

Closed
wants to merge 2 commits into from
Closed

Requests timeout fix #190

wants to merge 2 commits into from

Conversation

momoroboflow
Copy link

Description

Implements timeout and max_retries for any functions that POST. Found out that there was an occasional hang due to network issues and the POST request would wait forever.

Type of change

Please delete options that are not relevant.

  • Bug fix (non-breaking change which fixes an issue)
  • This change requires a documentation update

How has this change been tested, please provide a testcase or example of how you tested the change?

Ran with a hosted model and confirmed that pipeline no longer gets stuck and does not fail for occasional network hiccups.

Any specific deployment considerations

None, default arguments maintain original functionality

Docs

  • Docs updated? What were the changes: Updated in-code docstrings; need to update GitBook

@CLAassistant
Copy link

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.
You have signed the CLA already but the status is still pending? Let us recheck it.

@robiscoding
Copy link
Collaborator

We should allow the caller to handle how they want to retry failed calls to predict. Retry backoff can be helpful in some cases, but not where, for example, there is no internet connection. Additionally, this implementation duplicates the __failsafe_post method across multiple files, which is undesirable because it'll require changing them all anytime we change one.

@robiscoding robiscoding closed this Oct 5, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants