[Python] Add support for request timeout#4173
Merged
wing328 merged 3 commits intoswagger-api:masterfrom Nov 11, 2016
Merged
Conversation
Contributor
|
Travis CI failed with the following error: Ref: https://api.travis-ci.org/jobs/175005279/log.txt?deansi=true Please take a look when you've time. |
Contributor
Author
|
I've updated the test and it should pass now. |
davidgri
pushed a commit
to davidgri/swagger-codegen
that referenced
this pull request
May 11, 2017
* [Python] Add support for request timeout * Update python petstore api * [Python] Add test for request timeout
|
@mbohlool @wing328 thank you for this feature! is there a way to configure this timeout when generating the client? We generate like this: But it seems the client side just uses urllib3's urlopen and the default timeout for that is infinite |
danking
added a commit
to danking/hail
that referenced
this pull request
Nov 20, 2018
Unfortunately, as far as I can tell, swagger-codgen providss no way to set a default timeout. Instead, I littered our code with explicit timeout arguments to k8s API calls. The best documentation of this feature of swagger-codegen that I have found is the PR that adds the feature: swagger-api/swagger-codegen#4173
danking
added a commit
to hail-is/hail
that referenced
this pull request
Nov 20, 2018
Unfortunately, as far as I can tell, swagger-codgen providss no way to set a default timeout. Instead, I littered our code with explicit timeout arguments to k8s API calls. The best documentation of this feature of swagger-codegen that I have found is the PR that adds the feature: swagger-api/swagger-codegen#4173
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
PR checklist
./bin/to update Petstore sample so that CIs can verify the change. (For instance, only need to run./bin/{LANG}-petstore.shand./bin/security/{LANG}-petstore.shif updating the {LANG} (e.g. php, ruby, python, etc) code generator or {LANG} client's mustache templates)2.3.0branch for breaking (non-backward compatible) changes.Description of the PR
Similar to #4166 adding support for a timeout flag called _request_timeout.
fixes #4169