specification icon indicating copy to clipboard operation
specification copied to clipboard

bom-ref help text needs tweaking ❗

Open prabhu opened this issue 9 months ago • 4 comments

bom-ref is a required attribute, so we need to remove the optional word from the description.

https://github.com/CycloneDX/specification/blob/d570ffb8956d796585b9574e57598c42ee9de770/schema/bom-1.6.schema.json#L3887

https://github.com/CycloneDX/specification/blob/d570ffb8956d796585b9574e57598c42ee9de770/schema/bom-1.6.schema.json#L3895

https://github.com/CycloneDX/specification/blob/d570ffb8956d796585b9574e57598c42ee9de770/schema/bom-1.6.schema.json#L4207

https://github.com/CycloneDX/specification/blob/d570ffb8956d796585b9574e57598c42ee9de770/schema/bom-1.6.schema.json#L4214

I think in 1.7 we can think of externalizing the help texts and referring to them with short codes. That way the description will be consistent and could be internationalized. Whether an attribute is required or not could be determined entirely from the required array.

prabhu avatar Mar 28 '25 09:03 prabhu

is removing the word "optional" not enough? is it really required in the help test, @stevespringett ?

jkowalleck avatar Mar 28 '25 11:03 jkowalleck

Lets just remove the word optional in this case.

stevespringett avatar Mar 28 '25 16:03 stevespringett

More instance (found with cdxgenGPT!):

https://github.com/CycloneDX/specification/blob/d570ffb8956d796585b9574e57598c42ee9de770/schema/bom-1.6.schema.json#L4039 https://github.com/CycloneDX/specification/blob/d570ffb8956d796585b9574e57598c42ee9de770/schema/bom-1.6.schema.json#L4363

I have uploaded the cyclonedx json schema. I am looking for mistakes in the description text where the word "optional" is used while the attribute is part of the required array. Couple of examples: `workflow.bom-ref` attribute has the description beginning with "An optional identifier", while bom-ref is part of the required array 

json
"required": [
        "bom-ref",
        "uid",
        "taskTypes"
      ]

Similar mistake could also be found for `workspace.bom-ref`. Can you review the attached file and find other attributes with similar issues in description text?

Image

prabhu avatar Mar 29 '25 14:03 prabhu

#649 is probably a duplicate if this very ticket.

jkowalleck avatar Jun 12 '25 09:06 jkowalleck

will start working on a fix

jkowalleck avatar Sep 03 '25 08:09 jkowalleck

done via https://github.com/CycloneDX/specification/pull/680

jkowalleck avatar Sep 07 '25 10:09 jkowalleck