Skip to content

Commit 0e00d28

Browse files
Update changelog and docs
Signed-off-by: Ayan Sinha Mahapatra <ayansmahapatra@gmail.com>
1 parent 5768c8c commit 0e00d28

File tree

2 files changed

+575
-121
lines changed

2 files changed

+575
-121
lines changed

CHANGELOG.rst

Lines changed: 69 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,67 @@ Changelog
22
=========
33

44

5-
65
v32.0.0 (next next, roadmap)
7-
----------------------------------
6+
----------------------------
7+
8+
Important API changes:
9+
~~~~~~~~~~~~~~~~~~~~~~
10+
11+
- The data structure of the JSON output has changed for licenses at resource level:
12+
13+
- We now return ``license_detections`` information at the manifest file-level
14+
rather than ``licenses``. This three data attributes: ``license_expression``,
15+
``detection_log`` and ``matches``. Here ``matches`` is similar to previous
16+
``licenses`` with some additional changes.
17+
18+
- A new attribute ``license_clues`` was added, which has license matches same
19+
as the ``matches`` field in ``license_detections``. This has license matches
20+
which are mere clues and not proper detections.
21+
22+
- The ``license_expressions`` field was removed, which was a list of license
23+
expressions and it was replaced with ``detected_license_expression`` which
24+
was a single license expression. Similarly ``spdx_license_expressions`` was
25+
removed and replaced by ``detected_license_expression_spdx``.
26+
27+
- See `license updates doc <https://scancode-toolkit.readthedocs.io/en/latest/explanations/license-detection-reference.html#change-in-license-data-format-resource>`_
28+
for examples and more details.
29+
30+
- Similarly the data structure of license fields in "package_data" has also
31+
changed, along with codebase level ``packages`` data:
32+
33+
- There's a ``license_detections`` field with the detections, same as the
34+
resource ``license_detections``, and there's also ``other_license_detections``.
35+
Here ``license_detections`` has the detections for the primary/declared
36+
licenses, and the rest of the secondary detecions are at
37+
``other_license_detections``.
38+
39+
- The ``license_expression`` field has been dropped, and instead we have
40+
``declared_license_expression`` and ``other_license_expression`` fields
41+
with their SPDX counterparts: ``declared_license_expression_spdx`` and
42+
``other_license_expression_spdx``.
43+
44+
- The ``declared_license`` field also has been renamed to ``extracted_license_statement``,
45+
and previously this ``declared_license`` field could be a list, a dict or a string, but
46+
now ``extracted_license_statement`` is always a string.
47+
48+
See `license updates doc <https://scancode-toolkit.readthedocs.io/en/latest/explanations/license-detection-reference.html#comparision-before-after-license-references>`_
49+
for examples and more details.
50+
51+
- Additionally the ``--get-license-data`` option would add two codebase level attributes:
52+
``license_references`` and ``rule_references`` which are lists of license and rules
53+
respectively. This also removes the corresponding fields from ``matches`` in
54+
``license_detections`` as they are referenced in these two codebase level fields. See
55+
`license updates doc <https://scancode-toolkit.readthedocs.io/en/latest/explanations/license-detection-reference.html#change-in-license-data-format-package>`_
56+
for examples and more details.
57+
58+
- The data structure of License matches has also changed: we had ``key`` i.e.
59+
a license key for each match, but now we have ``license_expression`` instead and
60+
we have a flat data structure instead of the ``matched_rule`` inside of ``matches``.
61+
Now we also have a ``licenses`` list with data for all the licenses present in the
62+
license expression.
63+
See `license updates doc <https://scancode-toolkit.readthedocs.io/en/latest/explanations/license-detection-reference.html#licensematch-result-data>`_
64+
for examples and more details.
65+
866

967
Package detection:
1068
~~~~~~~~~~~~~~~~~~
@@ -46,6 +104,8 @@ License detection:
46104
matches in a larger license detecion. This remove a larger number of false
47105
positive or ambiguous license detections.
48106

107+
https://github.com/nexB/scancode-toolkit/issues/2878
108+
49109
- The data structure of the JSON output has changed for licenses. We now
50110
return match details once for each matched license expression rather than
51111
once for each license in a matched expression. There is a new top-level
@@ -67,16 +127,21 @@ License detection:
67127
with the "scancode-reindex-licenses" command and also a new "--only-builtin"
68128
option to only use the builtin licenses to build the cache.
69129

130+
https://github.com/nexB/scancode-toolkit/issues/480
131+
70132
- Scancode LICENSE and RULE files now also contain their data as YAML frontmatter,
71133
which previously used to be in their respective YAML files. This reduces number of
72134
files in those directories, 'rules' and 'licenses' to half. Git line history is
73135
preserved for the files.
74136

75-
- A new command line option "--get-license-data" is added to dump license data in
137+
https://github.com/nexB/scancode-toolkit/issues/3049
138+
139+
- A new command line option ``--get-license-data`` is added to dump license data in
76140
JSON, YAML and HTML formats, and also generates a local index and a static website
77141
to view the data. This will essentially be an API/way to get scancode license data
78-
as opposed to just reading the files.
142+
as opposed to just reading the files.
79143

144+
https://github.com/nexB/scancode-toolkit/issues/2738
80145

81146
Package detection:
82147
~~~~~~~~~~~~~~~~~~~~~

0 commit comments

Comments
 (0)