Skip to content

Commonise licence parsing (Figshare/Zenodo) #37

@rhigman

Description

@rhigman

Both fsuploader and zenodouploader use regex to normalise the work licence retrieved from Thoth before trying to match it against the licence options provided by the target platform. The matching logic and expression used in each module are slightly different. Investigate whether they could be commonised.

  • The Zenodo expression is more thorough about removing non-distinctive CC suffixes (/deed, /legalcode) from the licence URL. It would be beneficial to replicate this for the Figshare check.
  • Be aware that pre-4.0 CC licences may have per-country variants represented by suffixes which are distinctive (e.g. /us, /br).
    • At the moment, for a Figshare repository whose licence list contained e.g. by/3.0/us but not by/3.0 (unlikely but possible), a false positive match would be returned for a Thoth by/3.0 licence.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions