-
-
Notifications
You must be signed in to change notification settings - Fork 38
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
JSON output does not guarantee component.version
value
#248
Labels
Comments
metadata.component.version
value
metadata.component.version
valuecomponent.version
value
according to the specs JSON schema v1.3 the therefore described behavior is clearly a bug |
jkowalleck
added a commit
that referenced
this issue
Jan 28, 2022
jkowalleck
added a commit
that referenced
this issue
Jan 28, 2022
jkowalleck
added a commit
that referenced
this issue
Jan 28, 2022
jkowalleck
added a commit
that referenced
this issue
Jan 29, 2022
jkowalleck
added a commit
that referenced
this issue
Feb 2, 2022
…ormalize optional `version` (#247) * Changed * Private/protected properties of Component models are no longer directly accessible. ([#233] via [#247]) Access via public getter/setter. * Fixed * Normalization guarantees `component.version`. ([#248] via [#247]) * Component's constructor may detect & set `autor` based on package info. ([#246] via [#247]) * Added * JSDoc for Component model. ([#220] via [#247]) [#220]: #220 [#233]: #233 [#246]: #246 [#247]: #247 [#248]: #248 --- * Component rework detect component.author - fixes #246 normalize empty component.version - fixes #248 add JSDoc - #220 use private properties - #233 Signed-off-by: Jan Kowalleck <jan.kowalleck@gmail.com> * use `@babel/eslint-parser` Signed-off-by: Jan Kowalleck <jan.kowalleck@gmail.com> * update locked dependencies and lockfile format Signed-off-by: Jan Kowalleck <jan.kowalleck@gmail.com> * CT/CI generates jsdoc & play with jsdoc Signed-off-by: Jan Kowalleck <jan.kowalleck@gmail.com> * wrote history Signed-off-by: Jan Kowalleck <jan.kowalleck@gmail.com> * slacked components getterusage internally Signed-off-by: Jan Kowalleck <jan.kowalleck@gmail.com> * fixed JSDoc `object` annotation Signed-off-by: Jan Kowalleck <jan.kowalleck@gmail.com>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I was using the JSON output of this tool as an input for another tool. I implemented a validation function in python for my other tool in order to ensure its correctness before processing the file, and can be seen as follows:
In this case I was using I created a BoM using schema v1.3 and noticed that there was a
version
value missing from the component within the optionalmetadata
property, and was throwing an error as invalid.In the schema file bom-1.3.schema.json, the optional metadata section, allows for components to be listed and references the component in the
#/definitions/component
section, where a version is required. In this case, there was no version associated with the component found in the metadata secion.The output is therefore non-compliant to the v1.3 schema standard, and the output should be verified to ensure that it is compliant before outputting to the user.
The text was updated successfully, but these errors were encountered: