Skip to content

Commit 0a4972e

Browse files
authored
Merge branch 'develop' into 2110-dart-pubspec
2 parents c5a1bd4 + 3be07db commit 0a4972e

File tree

2,850 files changed

+340978
-10508
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

2,850 files changed

+340978
-10508
lines changed

CHANGELOG.rst

Lines changed: 97 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,12 @@ Changelog
44
v21.x.x (next, future)
55
-----------------------
66

7-
Breaking API changes:
8-
~~~~~~~~~~~~~~~~~~~~~
7+
Important API changes:
8+
~~~~~~~~~~~~~~~~~~~~~~~~
9+
10+
- The data structure of the JSON output is now versioned and the next version
11+
is available with a new command line option. We are also documenting a new
12+
and clear API policy and backward compatibility policy.
913

1014
- The data structure of the JSON output has changed for copyrights, authors
1115
and holders: we now use proper name for attributes and not a generic "value".
@@ -23,6 +27,83 @@ Breaking API changes:
2327
that contains each package instance that can be aggregating data from
2428
multiple manifests for a single package instance.
2529

30+
- The data structure for HTML output has been changed to include emails and urls under the
31+
"infos" object. Now HTML template will output holders, authors, emails, and
32+
urls into separate tables like "licenses" and "copyrights".
33+
34+
Copyright detection:
35+
~~~~~~~~~~~~~~~~~~~~
36+
37+
- The data structure in the JSON is now using consistently named attributes as
38+
opposed to a plain value.
39+
40+
41+
Package detection:
42+
~~~~~~~~~~~~~~~~~~
43+
44+
- Add support for OpenWRT packages.
45+
- Add support for Yocto/BitBake .bb recipes.
46+
- Add support to track installed files for each Package type.
47+
48+
49+
License detection:
50+
~~~~~~~~~~~~~~~~~~~
51+
52+
- Unknown licenses have a new flag "is_unknown" to identify them
53+
beyond just the naming convention of having "unknown" as part of their name.
54+
55+
- Rules that match at least one unknown license have a flag "has_unknown" set
56+
in the returned match results.
57+
58+
59+
Many thanks to every contributors that made this possible and in particular:
60+
61+
- Akanksha Garg @akugarg
62+
- Ayan Sinha Mahapatra @AyanSinhaMahapatra
63+
- Jono Yang @JonoYang
64+
- Philippe Ombredanne @pombredanne
65+
66+
67+
68+
v21.8.4
69+
---------
70+
71+
This is a minor bug fix release primarily for Windows installation.
72+
There is no feature change.
73+
74+
Installation:
75+
~~~~~~~~~~~~~~~~~~
76+
77+
- Application installation on Windows works again. This fixes #2610
78+
- We now build and test app bundles on all supported Python versions: 3.6 to 3.9
79+
80+
81+
Thank you to @gunaztar for reporting the #2610 bug
82+
83+
Documentation:
84+
~~~~~~~~~~~~~~~~~~
85+
86+
- Documentation is updated to reference supported Python versions 3.6 to 3.9
87+
88+
89+
90+
v21.7.30
91+
---------
92+
93+
This is a minor release with several bug fixes, major performance improvements
94+
and support for new and improved package formats
95+
96+
97+
Many thanks to every contributors that made this possible and in particular:
98+
99+
- Abhigya Verma @abhi27-web
100+
- Ayan Sinha Mahapatra @AyanSinhaMahapatra
101+
- Dennis Clark @DennisClark
102+
- Jono Yang @JonoYang
103+
- Mayur Agarwal @mrmayurgithub
104+
- Philippe Ombredanne @pombredanne
105+
- Pierre Tardy @tardyp
106+
26107

27108
Outputs:
28109
~~~~~~~~
@@ -31,28 +112,35 @@ Outputs:
31112
the JSON output
32113
- Add new Debian machine readable copyright output.
33114
- The CSV output "Resource" column has been renamed to "path".
34-
- The SPDX output now has the mandatory DocumentNamespace attribut per SPDX specs #2344
115+
- The SPDX output now has the mandatory DocumentNamespace attribute per SPDX specs #2344
35116

36117

37118
Copyright detection:
38119
~~~~~~~~~~~~~~~~~~~~
39120

40-
- The data structure in the JSON is now using consistently named attributes as
41-
opposed to a plain value.
42-
43121
- The copyright detection speed has been significantly improved with the tests
44122
taking roughly 1/2 of the time to run. This is achieved mostly by replacing
45123
NLTK with a the minimal and simplified subset we need in a new library named
46124
pygmars.
47125

126+
License detection:
127+
~~~~~~~~~~~~~~~~~~~
128+
129+
- Add new licenses: now tracking 1763 licenses
130+
- Add new license detection rules: now tracking 29475 license detection rules
131+
- We have also improved license expression parsing and processing
132+
48133

49134
Package detection:
50135
~~~~~~~~~~~~~~~~~~
51136

52-
- Add support for OpenWRT packages.
53-
- Add support for Yocto/BitBake .bb recipes.
137+
- The Debian packages declared license detection has been significantly improved.
54138
- The Alpine packages declared license detection has been significantly improved.
55-
- Add support to track installed files for each Package type.
139+
- There is new support for shell parsing and Alpine packages APKBUILD data collection.
140+
- There is new support for various Windows packages detection using multiple
141+
techniques including MSI, Windows registry and several more.
142+
- There is new support for Distroless Debian-like installed packages.
143+
- There is new support for Dart Pub package manifests.
56144

57145

58146
v21.6.7

CONTRIBUTING.rst

Lines changed: 21 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -134,25 +134,34 @@ To set up ScanCode for local development:
134134

135135
Run this command to configure ScanCode::
136136

137-
./configure
137+
./configure --dev
138138

139139
On Windows use instead::
140140

141-
configure
141+
configure --dev
142142

143-
Then run this: `source bin/activate` or `. bin/activate`
144-
(or run `bin\\activate` on Windows)
143+
Then activate the virtual environment::
144+
145+
source bin/activate
146+
147+
or
148+
149+
. bin/activate
150+
151+
On Windows use::
152+
153+
Scripts\activate
145154

146155
When you create a new terminal/shell to work on ScanCode rerun the activate step.
147156

148157
When you pull new code from git, rerun ./configure
149-
158+
150159

151160
5. Now you can make your code changes in your local clone.
152161
Please create new unit tests for your code. We love tests!
153162

154163
6. When you are done with your changes, run all the tests.
155-
Use this command::
164+
Use this command::
156165

157166
py.test
158167

@@ -162,25 +171,25 @@ To set up ScanCode for local development:
162171

163172
If you are running this on a RedHat based OS you may come across this
164173
failure::
165-
174+
166175
OSError: libbz2.so.1.0: cannot open shared object file: No such file or directory
167-
176+
168177
Try creating a symbolic link to libbz2.so.1.0 to solve this issue::
169178

170179
locate libbz2.so.1.0
171180
cd <resulting libbz2.so directory>
172181
sudo ln -s <your version of libbz2.so> libbz2.so.1.0
173-
182+
174183
See `this issue <https://github.com/nexB/scancode-toolkit/issues/443>`_ for more information.
175184

176185
7. Check the status of your local repository before commit, regarding files changed::
177-
186+
178187
git status
179188

180189

181190
8. Commit your changes and push your branch to your GitHub fork::
182191

183-
git add <file-changed-1> <file-changed-2> <file-changed-3>
192+
git add <file-changed-1> <file-changed-2> <file-changed-3>
184193
git commit -m "Your detailed description of your changes." --signoff
185194
git push <repository-alias-name> name-of-your-bugfix-or-feature
186195

@@ -196,7 +205,7 @@ create a pull request. You can add new commits to your branch as needed.
196205
For merging, your request would need to:
197206

198207
1. Include unit tests that are passing (run ``py.test``).
199-
2. Update documentation as needed for new API, functionality etc.
208+
2. Update documentation as needed for new API, functionality etc.
200209
3. Add a note to ``CHANGELOG.rst`` about the changes.
201210
4. Add your name to ``AUTHORS.rst``.
202211

INSTALL.rst

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -16,13 +16,12 @@ Prerequisites
1616
-------------
1717

1818
Before installing ScanCode make sure you have installed these prerequisites.
19-
The main one is a Python interpreter.
20-
Python 3.6 is required for the standard installation.
19+
The main one is to have Python installed version 3.6, 3.7, 3.8 or 3.9.
2120

2221
- For Linux(Ubuntu): ``sudo apt install python3.6-dev bzip2 xz-utils zlib1g libxml2-dev libxslt1-dev``
23-
- For MacOS: Install Python 3.6.8 from https://www.python.org/ftp/python/3.6.8/python-3.6.8-macosx10.9.pkg
24-
- For Windows: Install Python 3.6.8 from https://www.python.org/ftp/python/3.6.8/python-3.6.8-amd64.exe
25-
- For FreeBSD: (this ineeds to be documented)
22+
- For MacOS: Install Python 3.x from https://www.python.org/
23+
- For Windows: Install Python 3.x from https://www.python.org/ using the 64 bits amd64 variant
24+
- For FreeBSD: (this needs to be documented)
2625

2726
Refer `Prerequisites <https://scancode-toolkit.readthedocs.io/en/latest/getting-started/install.html#prerequisites>`_
2827
for detailed information on all different operating systems and Python versions.
@@ -46,9 +45,9 @@ Use a release download and install as an application
4645
Advanced installation: pip install a Python PyPI package
4746
--------------------------------------------------------
4847

49-
- Create a virtual environment for Python 3.6 (of higher) and activate it::
48+
- Create a virtual environment for Python 3.x and activate it::
5049

51-
virtualenv -p /usr/bin/python3.6 venv-scancode && source venv-scancode/bin/activate
50+
virtualenv -p python3 venv-scancode && source venv-scancode/bin/activate
5251

5352
- Run ``pip install scancode-toolkit[full]``
5453

README.rst

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -120,8 +120,7 @@ Installation
120120
============
121121

122122
Before installing ScanCode make sure that you have installed the prerequisites
123-
properly. This means installing Python (Python 3.6 or higher is required.
124-
When installing the app tarball or zip, only Python 3.6 is supported for now).
123+
properly. This means installing Python (Python 3.6 or higher is required).
125124

126125
See `prerequisites <https://scancode-toolkit.readthedocs.io/en/latest/getting-started/install.html#prerequisites>`_
127126
for detailed information on the support platforms and Python versions.

configure

Lines changed: 11 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -45,10 +45,12 @@ CLEANABLE="
4545
.eggs
4646
pip-selfcheck.json
4747
src/scancode_toolkit.egg-info
48+
src/scancode_toolkit_mini.egg-info
4849
SCANCODE_DEV_MODE
4950
man
5051
Scripts"
5152

53+
5254
# extra arguments passed to pip
5355
PIP_EXTRA_ARGS=" "
5456

@@ -65,12 +67,17 @@ CFG_BIN_DIR=$CFG_ROOT_DIR/$VIRTUALENV_DIR/bin
6567

6668
################################
6769
# scancode-specific: Thirdparty package locations and index handling
68-
# Do we have thirdparty/files? use the mit.LICENSE as a proxy
69-
if [[ -f "$CFG_ROOT_DIR/thirdparty/mit.LICENSE" ]]; then
70-
LINKS=$CFG_ROOT_DIR/thirdparty
70+
if [[ "$PYPI_LINKS" == "" ]]; then
71+
# Do we have thirdparty/files? use the mit.LICENSE as a proxy
72+
if [[ -f "$CFG_ROOT_DIR/thirdparty/mit.LICENSE" ]]; then
73+
LINKS=$CFG_ROOT_DIR/thirdparty
74+
else
75+
LINKS=https://thirdparty.aboutcode.org/pypi
76+
fi
7177
else
72-
LINKS=https://thirdparty.aboutcode.org/pypi
78+
LINKS=$PYPI_LINKS
7379
fi
80+
7481
PIP_EXTRA_ARGS="--no-index --find-links $LINKS"
7582
################################
7683

docs/source/cli-reference/output-format.rst

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,6 @@ following options.
2929
others. Scancode Workbench and other applications that use Scancode Result data as input accept
3030
only the ``json`` format.
3131

32-
.. include:: /rst_snippets/note_snippets/output_json_notdef.rst
33-
3432
The following code performs a scan on the samples directory, and publishes the results in
3533
``json`` format::
3634

@@ -179,6 +177,7 @@ following options.
179177
"short_name": "MIT Old Style",
180178
"category": "Permissive",
181179
"is_exception": false,
180+
"is_unknown": false,
182181
"owner": "MIT",
183182
"homepage_url": "http://fedoraproject.org/wiki/Licensing:MIT#Old_Style",
184183
"text_url": "http://fedoraproject.org/wiki/Licensing:MIT#Old_Style",

docs/source/cli-reference/synopsis.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -228,6 +228,7 @@ A sample JSON output for an individual file will look like::
228228
"short_name": "MIT Old Style",
229229
"category": "Permissive",
230230
"is_exception": false,
231+
"is_unknown": false,
231232
"owner": "MIT",
232233
"homepage_url": "http://fedoraproject.org/wiki/Licensing:MIT#Old_Style",
233234
"text_url": "http://fedoraproject.org/wiki/Licensing:MIT#Old_Style",

docs/source/conf.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,8 @@
1818
# -- Project information -----------------------------------------------------
1919

2020
project = 'ScanCode-Toolkit'
21-
copyright = '2019 ScanCode-Toolkit.org'
22-
author = 'ScanCode-Toolkit.org'
21+
copyright = 'nexB Inc. and others.'
22+
author = 'AboutCode.org authors and contributors'
2323

2424

2525
# -- General configuration ---------------------------------------------------

0 commit comments

Comments
 (0)