EOSC-synergy / sqaaas-web

Software Quality Assurance as a Service (SQAaaS) Web
https://sqaaas.eosc-synergy.eu
GNU General Public License v3.0
2 stars 3 forks source link

Display badge-related criteria results #153

Closed orviz closed 1 year ago

orviz commented 2 years ago

Not all the criteria is relevant for the badge issuance process. For instance, although the QC.Met is theoretically part of the bronze category for software, there are no MUST subcriteria defined for such criterion, and thus, the criterion is not considered when issuing badges. The criteria that matters for this issue are the ones actually considered in the badge issuance process. In the previous example they are QC.Lic, QC.Acc and QC.Doc (all of them contain MUST subcriteria).

The purpose of this issue is to make available in the final view the set of criteria (not subcriteria) being fulfilled and not fulfilled for each badge category. This could be presented as a sort of table having each row the criteria (showing whether they are fulfilled or not fulfilled) that are considered for each type of badge category (gold, silver, bronze). The latter represented by (gold, silver, bronze) icons.

This information shall be displayed next to the badge data (image, verfication URL, etc.)

orviz commented 2 years ago

A first approach is available in the API spec release/2.5.0. It adds the badge:<type>:<criteria> property where each class of badge contains an object with the to_fulfill, missing and fulfilled arrays that contain the list of relevant criterion IDs, such as follows:

GET https://api-dev.sqaaas.eosc-synergy.eu/pipeline/assessment/{pipeline_id}/output


{
  "report": { },
  "badge": {
    "software": {
      "criteria": {
        "bronze": {
          "to_fulfill": ["criterion_1", "criterion_4"],
          "missing": [],
          "fulfilled": []
        },
        "silver": {
          "to_fulfill": [],
          "missing": [],
          "fulfilled": []
        },
        "gold": {
          "to_fulfill": [],
          "missing": [],
          "fulfilled": []
        },
      },
      "data": {      },
      "share": "<html>..</html>",
      "verification_url": "http://example.com"
    },
  }
}
orviz commented 1 year ago

Addressed in https://github.com/EOSC-synergy/sqaaas-web/pull/203

orviz commented 1 year ago

Released under 1.6.0