hdmf-dev / hdmf

The Hierarchical Data Modeling Framework
http://hdmf.readthedocs.io
Other
46 stars 26 forks source link

Validating links across extensions can fail #525

Open rly opened 3 years ago

rly commented 3 years ago

Description

An IndexSeries type links to an ImageSeries. If an extension defines a new type ExtImageSeries that extends ImageSeries, then it should be valid for the IndexSeries to link to ExtImageSeries. However, validation fails.

This seems to be because the validator looks only at the current namespace and validates the types within that namespace, so ExtImageSeries is not known to the nwb.core namespace validator.

This is blocking correct validation of NWB files from the Allen Institute.

Environment

Python Executable: Conda
Python Version: Python 3.8
Operating System: Windows
HDMF Version: dev

Checklist

t-b commented 3 years ago

@rly

This is blocking correct validation of NWB files from the Allen Institute.

My turf (icephys data)?

rly commented 3 years ago

@t-b This is actually for non-icephys data.

Further investigation reveals that the validator is correctly not validating against the nwb.core namespace directly. Instead, what happens is that the file contains four extensions which include the nwb.core namespace and only one of them knows about ExtImageSeries. So when validating the file against any of the other three namespaces that do not know about ExtImageSeries, validation of the IndexSeries fails.

mavaylon1 commented 4 months ago

Hey @rly is this something I can mark for the next release on June 11?