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

NanopubClient server recon fails on timeouts #163

Open
Ostrzyciel opened this issue Nov 8, 2023 · 0 comments
Open

NanopubClient server recon fails on timeouts #163

Ostrzyciel opened this issue Nov 8, 2023 · 0 comments

Comments

@Ostrzyciel
Copy link
Contributor

In the NanopubClient._query_grlc_try_servers method, all available grlc servers are tried by checking if they don't return HTTP 502. This breaks on other types of failures, like timeouts. If one of the server times out (and currently https://openphacts.cs.man.ac.uk/nanopub/grlc/api/local/local/ does), the method raises an exception and everything falls apart.

A workaround is to modify the grlc_urls field to exclude the server producing timeouts.

A permanent solution would be to probably rewrite this method, including shorter timeouts (the default one is very long) and handling for more HTTP status (anything that isn't 200 = error?).

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

No branches or pull requests

1 participant