Skip to content

Commit 2629008

Browse files
Fix test failures with regen
Signed-off-by: Ayan Sinha Mahapatra <[email protected]>
1 parent 9cc72ce commit 2629008

File tree

6 files changed

+131
-18
lines changed

6 files changed

+131
-18
lines changed

src/licensedcode/data/licenses/openai-tou-20230314.LICENSE

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,12 +8,12 @@ homepage_url: https://openai.com/policies/terms-of-use
88
spdx_license_key: LicenseRef-scancode-openai-tou-20230314
99
ignorable_copyrights:
1010
- (c) Arbitration Forum
11-
- (c) Price Changes. We
11+
- (c) Price Changes
1212
- (c) Processing of Personal Data
1313
- (c) U.S. Federal Agency Entities
1414
ignorable_holders:
1515
- Arbitration Forum
16-
- Price Changes. We
16+
- Price Changes
1717
- Processing of Personal Data
1818
- U.S. Federal Agency Entities
1919
ignorable_urls:

tests/formattedcode/data/common/manifests-expected.json

Lines changed: 22 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -471,7 +471,7 @@
471471
],
472472
"license_detections": [
473473
{
474-
"identifier": "cddl_1_0-ce8b3a58-f284-e7dd-22b3-c4d82f97dfe3",
474+
"identifier": "cddl_1_0-c6dbef4d-659c-289f-5ee9-1ca0278edad6",
475475
"license_expression": "cddl-1.0",
476476
"detection_count": 1
477477
},
@@ -695,6 +695,18 @@
695695
{
696696
"license_expression": "cddl-1.0",
697697
"matches": [
698+
{
699+
"score": 16.0,
700+
"start_line": 17,
701+
"end_line": 19,
702+
"matched_length": 3,
703+
"match_coverage": 100.0,
704+
"matcher": "2-aho",
705+
"license_expression": "unknown-license-reference",
706+
"rule_identifier": "license-intro_72.RULE",
707+
"rule_relevance": 16,
708+
"rule_url": "https://github.com/nexB/scancode-toolkit/tree/develop/src/licensedcode/data/rules/license-intro_72.RULE"
709+
},
698710
{
699711
"score": 82.35,
700712
"start_line": 18,
@@ -708,11 +720,11 @@
708720
"rule_url": "https://github.com/nexB/scancode-toolkit/tree/develop/src/licensedcode/data/rules/cddl-1.0_32.RULE"
709721
}
710722
],
711-
"identifier": "cddl_1_0-ce8b3a58-f284-e7dd-22b3-c4d82f97dfe3"
723+
"identifier": "cddl_1_0-c6dbef4d-659c-289f-5ee9-1ca0278edad6"
712724
}
713725
],
714726
"license_clues": [],
715-
"percentage_of_license_text": 8.09,
727+
"percentage_of_license_text": 9.25,
716728
"copyrights": [],
717729
"holders": [],
718730
"authors": [],
@@ -1015,7 +1027,13 @@
10151027
"percentage_of_license_text": 5.51,
10161028
"copyrights": [],
10171029
"holders": [],
1018-
"authors": [],
1030+
"authors": [
1031+
{
1032+
"author": "Spencer Alger",
1033+
"start_line": 7,
1034+
"end_line": 8
1035+
}
1036+
],
10191037
"files_count": 0,
10201038
"dirs_count": 0,
10211039
"size_count": 0,

tests/formattedcode/data/common/manifests-expected.jsonlines

Lines changed: 22 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -507,7 +507,7 @@
507507
{
508508
"license_detections": [
509509
{
510-
"identifier": "cddl_1_0-ce8b3a58-f284-e7dd-22b3-c4d82f97dfe3",
510+
"identifier": "cddl_1_0-c6dbef4d-659c-289f-5ee9-1ca0278edad6",
511511
"license_expression": "cddl-1.0",
512512
"detection_count": 1
513513
},
@@ -741,6 +741,18 @@
741741
{
742742
"license_expression": "cddl-1.0",
743743
"matches": [
744+
{
745+
"score": 16.0,
746+
"start_line": 17,
747+
"end_line": 19,
748+
"matched_length": 3,
749+
"match_coverage": 100.0,
750+
"matcher": "2-aho",
751+
"license_expression": "unknown-license-reference",
752+
"rule_identifier": "license-intro_72.RULE",
753+
"rule_relevance": 16,
754+
"rule_url": "https://github.com/nexB/scancode-toolkit/tree/develop/src/licensedcode/data/rules/license-intro_72.RULE"
755+
},
744756
{
745757
"score": 82.35,
746758
"start_line": 18,
@@ -754,11 +766,11 @@
754766
"rule_url": "https://github.com/nexB/scancode-toolkit/tree/develop/src/licensedcode/data/rules/cddl-1.0_32.RULE"
755767
}
756768
],
757-
"identifier": "cddl_1_0-ce8b3a58-f284-e7dd-22b3-c4d82f97dfe3"
769+
"identifier": "cddl_1_0-c6dbef4d-659c-289f-5ee9-1ca0278edad6"
758770
}
759771
],
760772
"license_clues": [],
761-
"percentage_of_license_text": 8.09,
773+
"percentage_of_license_text": 9.25,
762774
"copyrights": [],
763775
"holders": [],
764776
"authors": [],
@@ -1069,7 +1081,13 @@
10691081
"percentage_of_license_text": 5.51,
10701082
"copyrights": [],
10711083
"holders": [],
1072-
"authors": [],
1084+
"authors": [
1085+
{
1086+
"author": "Spencer Alger",
1087+
"start_line": 7,
1088+
"end_line": 8
1089+
}
1090+
],
10731091
"files_count": 0,
10741092
"dirs_count": 0,
10751093
"size_count": 0,

tests/formattedcode/data/common/manifests-expected.yaml

Lines changed: 81 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -465,7 +465,7 @@ dependencies:
465465
datafile_path: manifests/npm-license-string/package.json
466466
datasource_id: npm_package_json
467467
license_detections:
468-
- identifier: cddl_1_0-ce8b3a58-f284-e7dd-22b3-c4d82f97dfe3
468+
- identifier: cddl_1_0-c6dbef4d-659c-289f-5ee9-1ca0278edad6
469469
license_expression: cddl-1.0
470470
detection_count: 1
471471
- identifier: apache_2_0-ec759ae0-ea5a-f138-793e-388520e080c0
@@ -1084,6 +1084,39 @@ license_references:
10841084
scancode_url: https://github.com/nexB/scancode-toolkit/tree/develop/src/licensedcode/data/licenses/mit.LICENSE
10851085
licensedb_url: https://scancode-licensedb.aboutcode.org/mit
10861086
spdx_url: https://spdx.org/licenses/MIT
1087+
- key: unknown-license-reference
1088+
language: en
1089+
short_name: Unknown License reference
1090+
name: Unknown License file reference
1091+
category: Unstated License
1092+
owner: Unspecified
1093+
homepage_url:
1094+
notes: This applies to the case of a file with no clear license, which may be referenced
1095+
via URL or text such as "See license in..." or "This file is licensed under...", but where
1096+
the reference cannot be resolved to a specific named, public license.
1097+
is_builtin: yes
1098+
is_exception: no
1099+
is_unknown: yes
1100+
is_generic: no
1101+
spdx_license_key: LicenseRef-scancode-unknown-license-reference
1102+
other_spdx_license_keys: []
1103+
osi_license_key:
1104+
text_urls: []
1105+
osi_url:
1106+
faq_url:
1107+
other_urls: []
1108+
key_aliases: []
1109+
minimum_coverage: '0'
1110+
standard_notice:
1111+
ignorable_copyrights: []
1112+
ignorable_holders: []
1113+
ignorable_authors: []
1114+
ignorable_urls: []
1115+
ignorable_emails: []
1116+
text:
1117+
scancode_url: https://github.com/nexB/scancode-toolkit/tree/develop/src/licensedcode/data/licenses/unknown-license-reference.LICENSE
1118+
licensedb_url: https://scancode-licensedb.aboutcode.org/unknown-license-reference
1119+
spdx_url: https://github.com/nexB/scancode-toolkit/tree/develop/src/licensedcode/data/licenses/unknown-license-reference.LICENSE
10871120
license_rule_references:
10881121
- license_expression: apache-2.0
10891122
identifier: apache-2.0_65.RULE
@@ -1243,6 +1276,33 @@ license_rule_references:
12431276
You should have received a copy of the GNU Lesser General Public License
12441277
along with this library; if not, write to the Free Software Foundation, Inc.,
12451278
51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
1279+
- license_expression: unknown-license-reference
1280+
identifier: license-intro_72.RULE
1281+
language: en
1282+
rule_url: https://github.com/nexB/scancode-toolkit/tree/develop/src/licensedcode/data/rules/license-intro_72.RULE
1283+
is_license_text: no
1284+
is_license_notice: no
1285+
is_license_reference: no
1286+
is_license_tag: no
1287+
is_license_intro: yes
1288+
is_continuous: no
1289+
is_builtin: yes
1290+
is_from_license: no
1291+
is_synthetic: no
1292+
length: 3
1293+
relevance: 16
1294+
minimum_coverage: 80
1295+
referenced_filenames: []
1296+
notes:
1297+
ignorable_copyrights: []
1298+
ignorable_holders: []
1299+
ignorable_authors: []
1300+
ignorable_urls: []
1301+
ignorable_emails: []
1302+
text: |
1303+
<licenses>
1304+
<license>
1305+
<name>
12461306
- license_expression: mit
12471307
identifier: mit_30.RULE
12481308
language: en
@@ -1526,6 +1586,20 @@ files:
15261586
license_detections:
15271587
- license_expression: cddl-1.0
15281588
matches:
1589+
- score: '16.0'
1590+
start_line: 17
1591+
end_line: '19'
1592+
matched_length: 3
1593+
match_coverage: '100.0'
1594+
matcher: 2-aho
1595+
license_expression: unknown-license-reference
1596+
rule_identifier: license-intro_72.RULE
1597+
rule_relevance: 16
1598+
rule_url: https://github.com/nexB/scancode-toolkit/tree/develop/src/licensedcode/data/rules/license-intro_72.RULE
1599+
matched_text: |
1600+
<licenses>
1601+
<license>
1602+
<name>Common Development and Distribution License (CDDL) v1.0</name>
15291603
- score: '82.35'
15301604
start_line: 18
15311605
end_line: 20
@@ -1540,9 +1614,9 @@ files:
15401614
<license>
15411615
<name>Common Development and Distribution License (CDDL) v1.0</name>
15421616
<url>http://www.sun.com/cddl/cddl.html</url>
1543-
identifier: cddl_1_0-ce8b3a58-f284-e7dd-22b3-c4d82f97dfe3
1617+
identifier: cddl_1_0-c6dbef4d-659c-289f-5ee9-1ca0278edad6
15441618
license_clues: []
1545-
percentage_of_license_text: '8.09'
1619+
percentage_of_license_text: '9.25'
15461620
copyrights: []
15471621
holders: []
15481622
authors: []
@@ -1815,7 +1889,10 @@ files:
18151889
percentage_of_license_text: '5.51'
18161890
copyrights: []
18171891
holders: []
1818-
authors: []
1892+
authors:
1893+
- author: Spencer Alger
1894+
start_line: 7
1895+
end_line: 8
18191896
emails:
18201897
18211898
start_line: 9

tests/packagedcode/data/license_detection/reference-at-manifest/fizzler.expected.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@
8787
"other_license_expression": null,
8888
"other_license_expression_spdx": null,
8989
"other_license_detections": [],
90-
"extracted_license_statement": "{'@type': 'file', '#text': 'COPYING.txt'}",
90+
"extracted_license_statement": "'@type': file\n'#text': COPYING.txt\n",
9191
"notice_text": null,
9292
"source_packages": [],
9393
"extra_data": {},
@@ -300,7 +300,7 @@
300300
"other_license_expression": null,
301301
"other_license_expression_spdx": null,
302302
"other_license_detections": [],
303-
"extracted_license_statement": "{'@type': 'file', '#text': 'COPYING.txt'}",
303+
"extracted_license_statement": "'@type': file\n'#text': COPYING.txt\n",
304304
"notice_text": null,
305305
"source_packages": [],
306306
"file_references": [],

tests/summarycode/data/todo/no_todo/base64-arraybuffer.expected.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@
7777
"other_license_expression": null,
7878
"other_license_expression_spdx": null,
7979
"other_license_detections": [],
80-
"extracted_license_statement": "[{'type': 'MIT', 'url': 'https://github.com/niklasvh/base64-arraybuffer/blob/master/LICENSE-MIT'}]",
80+
"extracted_license_statement": "- type: MIT\n url: https://github.com/niklasvh/base64-arraybuffer/blob/master/LICENSE-MIT\n",
8181
"notice_text": null,
8282
"source_packages": [],
8383
"extra_data": {},
@@ -595,7 +595,7 @@
595595
"other_license_expression": null,
596596
"other_license_expression_spdx": null,
597597
"other_license_detections": [],
598-
"extracted_license_statement": "[{'type': 'MIT', 'url': 'https://github.com/niklasvh/base64-arraybuffer/blob/master/LICENSE-MIT'}]",
598+
"extracted_license_statement": "- type: MIT\n url: https://github.com/niklasvh/base64-arraybuffer/blob/master/LICENSE-MIT\n",
599599
"notice_text": null,
600600
"source_packages": [],
601601
"file_references": [],

0 commit comments

Comments
 (0)