-
Notifications
You must be signed in to change notification settings - Fork 3
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
31: Load data from URIs #37
Conversation
… open file handles under a single context.
…nd hdf5 file handle
…of opening file again
…nsibility in the context manager
…IO class member for string actions
…he cansas xml reader
…assume a file, uri, or xml string.
… files loaded locally as compared to a version available by uri
…athlib.path attributes for file pathing
…garding duplicate reader entries
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Tested with pytest and python -m sasmodels.compare sphere -data=https://github.com/SasView/sasdata/raw/master/test/sasdataloader/data/valid_cansas_xml.xml
I still think the CustomFileOpen is unnecessarily complicated but it works as is, and it is just as much effort to change in a future PR as it is to change in this PR.
This PR adds a few non-breaking enhancements to the data loader system to aid in scripting and web-facing capabilities.
urllib.request
, opens the file at from the web address.