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

Align traverse_thredds/nc_to_mmd with mmd.xsd #191

Open
ferrighi opened this issue Apr 27, 2022 · 4 comments
Open

Align traverse_thredds/nc_to_mmd with mmd.xsd #191

ferrighi opened this issue Apr 27, 2022 · 4 comments
Assignees
Labels
MMD-v4 issues to be solved in MMD-v4

Comments

@ferrighi
Copy link
Collaborator

Information extracted from thredds about for example related_information (https://github.com/metno/mmd/blob/master/bin/traverse_thredds#L158) are put in a sequence that do not match the xsd (https://github.com/metno/mmd/blob/master/xsd/mmd.xsd#L396) requirements.
For mmd the sequence is:

  1. type
  2. description
  3. resource

for traverse_thredds:

  1. resource
  2. type
  3. description

I am not sure there is a reason for the sequence, but we should either change the schema in xsd:all instead of xsd:sequence or change the extraction script, so to allow for an easy validation process.

This issue is valid also for data_access.

For the nc_to_mmd.py a similar issue is present with short/long name for data_center (https://github.com/metno/mmd/blob/master/mmd_utils/nc_to_mmd.py#L292) and projects.

If I get some confirmation about this or potential consequences, I can update the scripts or modify the schema.

@mortenwh
Copy link
Collaborator

mortenwh commented Apr 27, 2022 via email

@steingod
Copy link
Collaborator

I am not using the scripts under mmd anymore, but versions located in mdharvest (since it is related to the harvesting processes that are run). I will evaluate this request in relation to that version.

@ferrighi
Copy link
Collaborator Author

Revitalizing this a bit. The order of elements does not have a real value for us, as the elements can be in any order as long as they have the right occurrence and they follow the vocabulary list. I suggest we revise the xsd schema and this is because it makes a constraints with has no foundation. Not enforcing the sequence should not harm any systems from my point of view, as the new schema will just be less stringent. If you still follow a sequence, the records will still validate.

@ferrighi ferrighi added the MMD-v4 issues to be solved in MMD-v4 label Nov 29, 2024
@ferrighi
Copy link
Collaborator Author

This is linked to #267

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
MMD-v4 issues to be solved in MMD-v4
Projects
None yet
Development

No branches or pull requests

3 participants