Close netcdf dataset after getting its size#29
Open
ninsbl wants to merge 3 commits into
Open
Conversation
This was referenced Oct 1, 2021
added 2 commits
October 3, 2021 22:45
Author
|
So it seemed the main problem was actually the TCP connection that was kept alive (for some time) with a newer version of This could probably be solved more elegant, like e.g. here: |
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.
Thanks for this cool python library. I looked at alternatives (like siphon) but this one still is the most to the point solution with the features / functions I need.
Hopefully, the fact that there have not been any commits to the master branch the last years is a sign of the reliability of the library and that it just works (and not that it is no longer actively maintained).
When I used it to crawl a larger Thredds server, I noticed that the server at some point returned a
502 Bad Gatewayerror. It may be related to the issue I try to address in this PR, that netcdf files are not closed after their size is computed, leaving the server with plenty of open datasets?Another related question is, if I am not interested in the size of a dataset, but just want to get the URLs opening the dataset and computing it`s size is time spent unneccessary. Would it be acceptable for you to change the default, that the size is only computed on user request? I could have a look at that and make a separate PR...
But if this library is no longer maintained, I would be really happy if you could point me to an alternative library that could be used as a replacement (with the same features)...