-
Notifications
You must be signed in to change notification settings - Fork 6
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
Handle connection errors in cache? #17
Comments
@naustica Could you talk a little bit more about what you mean by a report? |
something like:
|
doi | error |
---|---|
10.3253/dga.dsfs | Unpaywall response |
10.214134/afsaf | Timeout... |
Or do you have a better idea?
ok, the table has just been converted to markdown. Imagine that as a plain python table |
Ok. Right now dois are requested one-by-one, so I guess it would make sense to add a function that takes in a list of dois and then prints this report to the console, if the console is the best place. |
@naustica What do you think about just a warning? |
@bganglia I dont know. I associate warnings with internal problems. But this is more of an external one. Or? But we can do that. |
@naustica Now that I think about it, a report would probably be easier to read anyway. Printing out a report sounds good to me. |
@bganglia Python provides also the tempfile module (https://docs.python.org/3.7/library/tempfile.html) which creates a temporary file that we could use to store dois from faulty connections. So we can create a temporary txt file that the user has access to. The tempfile would only exist for one session (I think) which is also nice. |
Failed requests should not be saved.
A report should be generated with the DOIs that have led to failed requests.
This was raised as part of the discussion in issue #12
The text was updated successfully, but these errors were encountered: