aboutcode-org / aboutcode-org/scancode-toolkit

Support reporting unknown SPDX LicenseRef as their own license

Đang mở
#2,650 1 bình luận 0 reaction 1 người được giao Được @AyanSinhaMahapatra nhận Xem trên GitHub
new feature
Ngôn ngữ chính
Python
Star
2.6k
Fork
791
Merge trung bình
1 ngày 12 giờ
Pull request đã merge (30 ngày)
5

Mô tả

This is split from https://github.com/nexB/scancode-toolkit/issues/2502#issuecomment-864386537

In there @soimkim wrote

> I also have a similar issue.
I want to print the items marked with SPDX License, but the ScanCode json result is output as follows.

- Information written to the file:
`# SPDX-License-Identifier: LicenseRef-Sample-Proprietary`

- ScanCode json result :
```JSON
"licenses": [
{
"key": "unknown-spdx",
"score": 83.33,
"name": "Unknown SPDX license detected but not recognized",
"short_name": "unknown SPDX",
"category": "Unstated License",
"is_exception": false,
"owner": "Unspecified",
"homepage_url": null,
"text_url": "",
"reference_url": "https://scancode-licensedb.aboutcode.org/unknown-spdx",
"scancode_text_url": "https://github.com/nexB/scancode-toolkit/tree/develop/src/licensedcode/data/licenses/unknown-spdx.LICENSE",
"scancode_data_url": "https://github.com/nexB/scancode-toolkit/tree/develop/src/licensedcode/data/licenses/unknown-spdx.yml",
"spdx_license_key": "LicenseRef-scancode-unknown-spdx",
"spdx_url": "https://github.com/nexB/scancode-toolkit/tree/develop/src/licensedcode/data/licenses/unknown-spdx.LICENSE",
"start_line": 3,
"end_line": 3,
"matched_rule": {
"identifier": "spdx-license-identifier: unknown-spdx",
"license_expression": "unknown-spdx",
"licenses": [
"unknown-spdx"
],
```

>Although it is not a license registered in SPDX, is there a way to print the License ID ("Sample-Proprietary" in the example above) if it is written according to the notation of the SPDX License?

>If "key" extracted as "unknown-spdx", how about outputting "identifier" in "matched_rule" as License ID written?

Hướng dẫn đóng góp

Mở hướng dẫn đóng góp

Đánh giá

Issue này chưa được đánh giá.

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.