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

Schema "bom-1.5.xsd" is different from "bom-1.5.schema.json" #330

Closed
SpessartZiegler opened this issue Oct 31, 2023 · 2 comments
Closed

Comments

@SpessartZiegler
Copy link

SpessartZiegler commented Oct 31, 2023

If I validate a JSON file with no id or name for a license I got an error.
The schema is clear for me (see "Schema JSON.jpg" oneOf required.)
Schema JSON

If I validate a XML file with no id or name for a license I got the message that the file is okay.
It's clear for me (see "XSD,jpg" choice minOccurs="0")
XSD

If I change the minOccurs for id and name to "1" then the validation generates an error that the id or name is missing for a license.

It is the same for other "Choice"s in the XSD. In my point of view you will not get the same validation for JSON and XML files. Especially if you convert a valid XML file to JSON you will get an invalid file because some required entries are missing.

XSD.zip

@jkowalleck
Copy link
Member

duplicates #288

@jkowalleck jkowalleck closed this as not planned Won't fix, can't repro, duplicate, stale Oct 31, 2023
@jkowalleck
Copy link
Member

the JSON schema is the correct one for this particular detail.
the XML schema will be adjusted in v1.6 -- probably via #292

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

No branches or pull requests

2 participants