-
Notifications
You must be signed in to change notification settings - Fork 84
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
NWBHDF5IO ER and ER_Manager #1684
Conversation
Codecov Report
@@ Coverage Diff @@
## dev #1684 +/- ##
==========================================
+ Coverage 91.93% 91.96% +0.03%
==========================================
Files 26 27 +1
Lines 2592 2602 +10
Branches 679 680 +1
==========================================
+ Hits 2383 2393 +10
Misses 134 134
Partials 75 75
Flags with carried forward coverage won't be shown. Click here to find out more.
📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more |
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.
Other than deciding whether adding external_resources should be moved to HDMF, this PR looks good to me.
@oruebel I wanted to go a bit further with the ER logic in (hdmf-dev/hdmf#895) where the external_resources variable would be set to a read instance from the path, but this is not possible due HDMFIO and HDF5IO being imported in the hdmf/common init.py for namespace validation and will throw a circular import. As a result, the solution I came up with is that the variable is set to the path in HDMFIO and HDF5IO, but instantiated here. We need to merge the hdmf ticket, do a release, and change the minimum hdmf version here. Thoughts? |
If I understand it correctly you only need the |
Local import makes sense. Pending approval of the hdmf PR. |
@oruebel can you do one last look through? Not much changed since after your approval, but I removed the logic for linking resources since that moved to hdmf, I updated the reqs to the release of hdmf 3.7, and I added an ignore to codecov for resources.py. |
Why ignore coverage testing of this file? |
There's nothing to test and coverage was flagging it. Edit: created a test similar to test_core.py |
Motivation
The two changes is to add the ability to set an instance of ExternalResources for the NWBFile and NWBHDF5IO.
This is the first integration of ExternalResources into pynwb. The file is able to be linked to an instance of ExternalResources, while remaining separate during read/write.
How to test the behavior?
There is a test for resources via test_resources.py. The NWBFile operates as it previously did with added functionality to support ExternalResources.
Checklist
flake8
from the source directory.