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

Timeout #226

Open
fifa2017player opened this issue Dec 19, 2016 · 6 comments
Open

Timeout #226

fifa2017player opened this issue Dec 19, 2016 · 6 comments

Comments

@fifa2017player
Copy link

I noticed last night that for some reason a few requests made were just hanging for couple of hours for some reason, before an ExpiredSession gets raised. It would be great if when making requests to the server there is someway to specify a timeout, so that if the server just hangs, we don't wait indefinitely.

@oczkers
Copy link
Member

oczkers commented Dec 28, 2016

I was sure requests has default timeout but looks like it's not set at all, thanks for pointing out.

@oczkers
Copy link
Member

oczkers commented Dec 28, 2016

TODO:

@oczkers oczkers changed the title set timeout when making requests? Timeout Dec 28, 2016
oczkers added a commit that referenced this issue Dec 28, 2016
@fifa2017player
Copy link
Author

Thanks!

@oczkers
Copy link
Member

oczkers commented Jan 10, 2017

I'll reopen this until todo is complete :-)

@oczkers oczkers reopened this Jan 10, 2017
@converge
Copy link

@oczkers "some kind of retrying connection feature".

I do it in my bot catching exceptions and making it restart after 15 minutes for example. I'm able to do it, because I have the login information in my database, so, when I need to reconnect, I just have to connect to the database, retrieve login information and try again.

The API doesn't save login information (and it's right for doing it), so, how could it reconnnect when something interrupt the connection ?

@oczkers
Copy link
Member

oczkers commented Jan 11, 2017

@converge

I do it in my bot catching exceptions and making it restart after 15 minutes for example.

I meant waiting x seconds and retrying for x times and if finally all that fails then throw exception. One bad request is definitely not enought to crash whole application.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants