aboutcode-toolkit icon indicating copy to clipboard operation
aboutcode-toolkit copied to clipboard

Name should not be mandatory

Open pombredanne opened this issue 6 years ago • 7 comments

From a package and attribution generation point of view, the "name" field is not essential, yet a check fails with a "CRITICAL: Field name is required" if missing

pombredanne avatar Oct 23 '18 16:10 pombredanne

@chinyeungli Thank you ++ that was fast :+1:

pombredanne avatar Oct 24 '18 01:10 pombredanne

actually I was thinking about this earlier as the "name" field is only meaningful for component but not for package.

chinyeungli avatar Oct 24 '18 01:10 chinyeungli

@chinyeungli actually name is ambiguous IMHO and this will need to evolve. we have eventually package- and component-level data. The package would be identified by the Package URL or purl fields (type, namespace, name, version, qualifiers, subpath); and the component by its name/version. We would need to refine how we handle cases where we have data from boths

pombredanne avatar Oct 24 '18 17:10 pombredanne

reopen this as for some reasons, the name is required at the current code. Need to investigate again if the name is needed.

chinyeungli avatar Aug 11 '20 07:08 chinyeungli

Need to update the SPEC as the current SPEC treat name as a mandatory field (https://github.com/nexB/aboutcode-toolkit/blob/develop/SPECIFICATION.rst#other-mandatory-fields)

chinyeungli avatar Aug 14 '20 03:08 chinyeungli

actually from the attribution prespective, I think name is quite useful. For instance,

/project/org/apache/commons/logging/1.1/

if the ABOUT file doesn't have the name field, the attribution will not look nice:

  • It uses the about_resource as the name in attribution, but what if about_resource: ., then the name in the attribution is useless
  • we somehow get the directory name from the about_resource_path as the component name in the attribution 1.1 which is not really favourable
  • we use the path as the component name in the attribution which if we have much longer path will make the attribution non-readable.

However, if we have a name field Apache Commons Logging, the attribution notice will look much nicer and meaningful for the above 3 potential approaches.

I tend to keep the name as required. I will keep this ticket open for discussion.

chinyeungli avatar Oct 02 '20 09:10 chinyeungli

I am grouping this to https://github.com/orgs/nexB/projects/23 as this is related to attribution.

chinyeungli avatar Nov 18 '20 03:11 chinyeungli

Closing this. name should be mandatory and this is the only mandatory field.

chinyeungli avatar Jul 16 '24 08:07 chinyeungli