specification icon indicating copy to clipboard operation
specification copied to clipboard

Clarify swhid in documentation

Open prabhu opened this issue 1 year ago • 0 comments

The documentation for swhid is below:

Asserts the identity of the component using the Software Heritage persistent identifier (SWHID). The SWHID, if specified, MUST be valid and conform to the specification defined at: https://docs.softwareheritage.org/devel/swh-model/persistent-identifiers.html.

Many SWHID especially based on content and directory type are not unique and hence requires additional qualifiers such as anchors.

Below is a snippet from the swhid docs

This means, for example, that you should prefer swh:1:dir:a8eded6a2d062c998ba2dcc3dcb0ce68a4e15a58;anchor=swh:1:rel:22ece559cc7cc2364edc5e5593d63ae8bd229f9f over swh:1:rel:22ece559cc7cc2364edc5e5593d63ae8bd229f9f.

Similar to purl, I think the swhid attribute in the specification must allow qualifiers. This could be clarified via the documentation.

prabhu avatar Apr 23 '24 12:04 prabhu