Skip to content
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

Change: Only embed specs/namespaces for types that are included in NWB file on export #615

Draft
wants to merge 7 commits into
base: master
Choose a base branch
from

Conversation

ehennestad
Copy link
Collaborator

@ehennestad ehennestad commented Nov 4, 2024

Fix #607

Motivation

Ensure that only relevant namespaces/specifications are embedded in an NWB file. This issue suggests that such extra namespaces can cause errors when validating with NWBInspector.

How to test the behavior?

Export NWB file with types from a subset of available extension and check the file's `specification` group

Questions / todo

  • Are namespace names always specified in kebab-case? - Appears so
  •  Does matnwb always format namespace names as snake_case? - Appears so
  • Should the specification group be completely cleared before rewriting it if exporting to an existing file?
  • Check superclasses of each type and included namespace of superclasses as well
  • Add unit test

Checklist

  • Have you ensured the PR description clearly describes the problem and solutions?
  • Have you checked to ensure that there aren't other open or previously closed Pull Requests for the same change?
  • If this PR fixes an issue, is the first line of the PR description fix #XX where XX is the issue number?

Copy link

codecov bot commented Nov 4, 2024

Codecov Report

Attention: Patch coverage is 96.87500% with 1 line in your changes missing coverage. Please review.

Project coverage is 95.31%. Comparing base (bb9acbf) to head (eeb2006).

Files with missing lines Patch % Lines
+schemes/+utility/listNwbTypeHierarchy.m 87.50% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master     #615      +/-   ##
==========================================
+ Coverage   95.24%   95.31%   +0.06%     
==========================================
  Files         117      118       +1     
  Lines        4901     4931      +30     
==========================================
+ Hits         4668     4700      +32     
+ Misses        233      231       -2     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@ehennestad ehennestad changed the title Change: Only include namespaces for types that are included in NWB file on export Change: Only embed specs/namespaces for types that are included in NWB file on export Nov 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Feature]: Improve embedding of namespaces on nwbExport
1 participant