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

Order of elements matters but that is not documented #20

Open
2 tasks
mkuehbach opened this issue Jan 26, 2024 · 1 comment
Open
2 tasks

Order of elements matters but that is not documented #20

mkuehbach opened this issue Jan 26, 2024 · 1 comment
Labels
bug Something isn't working

Comments

@mkuehbach
Copy link
Collaborator

Scope:
nyaml converts a NeXus schema written in YAML into an NXDL.XML

Observation:
The order of childs to elements matters as observed when running make test on www.github.com/FAIRmat-NFDI/nexus_definitions make test for the following exemplar yaml and respective nxdl.xml application definition test files.nyaml2nxdl_order_matters.zip

My understanding
The reason is that childs of fieldType in nxdl.xsd are defined as childs of an xs:sequence not an xs:all
https://www.wilfried-grupe.de/XSD3_10.html

Necessary steps

  • Assure that nyaml2nxdl conversion strictly retains the order in how childs are arranged of a parent.
  • Write documentation which tells that the order of child is NOT arbitrary but has to be given exactly.

Further relevance
Also members and capabilities of NXDL that are less frequently used by current
FAIRmat-specific NeXus proposals use internally the xs:sequence environment.

@lukaspie
Copy link
Collaborator

Another point where this comes up: the nxdl specification requires the dimensions to be declared before any other attributes.

My suggestion: the ordering in the nyaml file can possibly be arbitrary, but the nyaml2nxdl forward tool should make sure that the ordering in xs:sequence is respected.

@lukaspie lukaspie added the bug Something isn't working label Jan 8, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants