Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 17 additions & 0 deletions CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,22 @@ Outputs:



30.0.1 - 2021-09-24
--------------------

This is a minor bug fix release for these bugs:

- https://github.com/nexB/scancode-toolkit/issues/2713
- https://github.com/nexB/scancode-toolkit/issues/2713

We now correctly work with all supported Click versions.

Thank you to:
- Konstantin Kochin @vznncv
- Thomas Druez @tdruez



30.0.0 - 2021-09-23
--------------------

Expand Down Expand Up @@ -204,6 +220,7 @@ particular:
- Sarita Singh @itssingh
- Siddhant Khare @Siddhant-K-code
- Soim Kim @soimkim
- Thomas Druez @tdruez
- Thorsten Godau @tgodau
- Yunus Rahbar @yns88

Expand Down
23 changes: 23 additions & 0 deletions azure-pipelines.yml
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,7 @@ jobs:
bin/pytest -n 3 -vvs --test-suite=all \
tests/licensedcode/test_zzzz_cache.py


- template: etc/ci/azure-posix.yml
parameters:
job_name: mac1014
Expand Down Expand Up @@ -159,6 +160,28 @@ jobs:
all: bin/pytest -n 2 -vvs tests/scancode/test_cli.py


################################################################################
# Test using many version of Click to work around regressions in API
################################################################################


- template: etc/ci/azure-posix.yml
parameters:
job_name: ubuntu20_test_all_supported_click_versions
image_name: ubuntu-20.04
python_versions: ['3.6', '3.7', '3.8', '3.9']
python_architecture: x64
test_suites:
click_versions: |
for clk_ver in 8.0.1 7.1.2 7.1.1 7.1 6.7;
do
bin/pip install click==$clk_ver;
bin/scancode -i samples/ -n3 --json foo.json;
bin/scancode -i --verbose samples/ -n3 --json foo.json;
done



################################################################################
# These jobs are using containers and their own Python 3.6
################################################################################
Expand Down
119 changes: 68 additions & 51 deletions etc/release/scancode-create-release.sh
Original file line number Diff line number Diff line change
Expand Up @@ -65,34 +65,42 @@ function run_app_smoke_tests {

echo " "
echo "### Testing app with Python $python_app_dot_version on OS: $operating_system"
archive_to_test=$(ls -1 -R release/archives/ | grep "$python_app_version-$operating_system")

echo "#### Testing $archive_to_test with Python $python_app_dot_version on OS: $operating_system"
# check if the tag file exist meaning we have already completed the tests
tag_file="scancode-release-tested-for-python-$python_app_dot_version-$operating_system"
if [ ! -f $tag_file ]; then
archive_to_test=$(ls -1 -R release/archives/ | grep "$python_app_version-$operating_system")

# Check checksum of archive and script since it transits through file.io
sha_arch=$(sha256sum release/archives/$archive_to_test | awk '{ print $1 }')
sha_py=$(sha256sum etc/release/scancode_release_tests.py | awk '{ print $1 }')
echo "#### Testing $archive_to_test with Python $python_app_dot_version on OS: $operating_system"

echo "#### Creating a temp archive that contains the tested archive: $archive_file and the test script"
archive_file=input.tar.gz
tar -czf $archive_file \
-C release/archives $archive_to_test \
-C ../../etc/release scancode_release_tests.py
# Check checksum of archive and script since it transits through file.io
sha_arch=$(sha256sum release/archives/$archive_to_test | awk '{ print $1 }')
sha_py=$(sha256sum etc/release/scancode_release_tests.py | awk '{ print $1 }')

tar -tvf $archive_file
echo "#### Creating a temp archive that contains the tested archive: $archive_file and the test script"
archive_file=input.tar.gz
tar -czf $archive_file \
-C release/archives $archive_to_test \
-C ../../etc/release scancode_release_tests.py

echo "#### Remote test command: python scancode_release_tests.py app $archive_to_test sha_arch:$sha_arch sha_py:$sha_py"
tar -tvf $archive_file

romp \
--interpreter cpython \
--architecture x86_64 \
--check-period 5 \
--version $python_app_dot_version \
--platform $operating_system \
--archive-file $archive_file \
--command "python scancode_release_tests.py app $archive_to_test $sha_arch $sha_py"
echo "#### Remote test command: python scancode_release_tests.py app $archive_to_test sha_arch:$sha_arch sha_py:$sha_py"

echo "#### RELEASE TEST: Completed App tests of $archive_to_test with Python $python_app_dot_version on OS: $operating_system"
romp \
--interpreter cpython \
--architecture x86_64 \
--check-period 5 \
--version $python_app_dot_version \
--platform $operating_system \
--archive-file $archive_file \
--command "python scancode_release_tests.py app $archive_to_test $sha_arch $sha_py"

echo "#### RELEASE TEST: Completed App tests of $archive_to_test with Python $python_app_dot_version on OS: $operating_system"
touch $tag_file
else
echo "#### RELEASE TEST: NOT RE-TESTING $archive_to_test with Python $python_app_dot_version on OS: $operating_system"
fi
}


Expand All @@ -109,46 +117,55 @@ function run_pypi_smoke_tests {
python_dot_versions=$2
operating_systems=$3

# check if the tag file exist meaning we have already completed the tests
tag_file="scancode-release-pypi-tested-for-$archive_to_test"

echo " "
echo "### Testing $archive_to_test with Pythons: $python_dot_versions on OSses: $operating_systems"

# Check checksum of archive and script since it transits through file.io
sha_arch=$(sha256sum release/pypi/$archive_to_test | awk '{ print $1 }')
sha_py=$(sha256sum etc/release/scancode_release_tests.py | awk '{ print $1 }')
if [ ! -f $tag_file ]; then

echo "#### Creating a temp archive that contains the tested archive: $archive_file and the test script"
archive_file=input.tar.gz
tar -czf $archive_file \
-C release/pypi $archive_to_test \
-C ../../etc/release scancode_release_tests.py
# Check checksum of archive and script since it transits through file.io
sha_arch=$(sha256sum release/pypi/$archive_to_test | awk '{ print $1 }')
sha_py=$(sha256sum etc/release/scancode_release_tests.py | awk '{ print $1 }')

tar -tvf $archive_file
echo "#### Creating a temp archive that contains the tested archive: $archive_to_test and the test script: release scancode_release_tests.py"
archive_file=input.tar.gz
tar -czf $archive_file \
-C release/pypi $archive_to_test \
-C ../../etc/release scancode_release_tests.py

echo "#### Remote test command: python scancode_release_tests.py pypi archive_to_test:$archive_to_test sha_arch:$sha_arch sha_py:$sha_py"
tar -tvf $archive_file

# build options for Python versions and OS
ver_opts=" "
for pdv in $python_dot_versions
do
ver_opts="$ver_opts --version $pdv"
done
echo "#### Remote test command: python scancode_release_tests.py pypi archive_to_test:$archive_to_test sha_arch:$sha_arch sha_py:$sha_py"

os_opts=" "
for os in $operating_systems
do
os_opts="$os_opts --platform $os"
done
# build options for Python versions and OS
ver_opts=" "
for pdv in $python_dot_versions
do
ver_opts="$ver_opts --version $pdv"
done

romp \
--interpreter cpython \
--architecture x86_64 \
--check-period 5 \
$ver_opts \
$os_opts \
--archive-file $archive_file \
--command "python scancode_release_tests.py pypi $archive_to_test $sha_arch $sha_py"
os_opts=" "
for os in $operating_systems
do
os_opts="$os_opts --platform $os"
done

echo "#### RELEASE TEST: Completed PyPI tests of $archive_to_test with Pythons: $python_dot_versions on OSses: $operating_systems"
romp \
--interpreter cpython \
--architecture x86_64 \
--check-period 5 \
$ver_opts \
$os_opts \
--archive-file $archive_file \
--command "python scancode_release_tests.py pypi $archive_to_test $sha_arch $sha_py"

echo "#### RELEASE TEST: Completed PyPI tests of $archive_to_test with Pythons: $python_dot_versions on OSses: $operating_systems"
touch $tag_file
else
echo "#### RELEASE TEST: NOT RE-TESTING Pypi $archive_to_test with Python $python_app_dot_version on OSses: $operating_systems"
fi

}

Expand Down
2 changes: 1 addition & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ cffi==1.14.5
chardet==4.0.0
click==8.0.1
colorama==0.4.4
commoncode==21.8.31
commoncode==30.0.0
construct==2.10.67
cryptography==3.4.7
debian-inspector==30.0.0
Expand Down
4 changes: 2 additions & 2 deletions setup-mini.cfg
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[metadata]
name = scancode-toolkit-mini
version = 30.0.0
version = 30.0.1
license = Apache-2.0 AND CC-BY-4.0 AND LicenseRef-scancode-other-permissive AND LicenseRef-scancode-other-copyleft

description = ScanCode is a tool to scan code for license, copyright, package and their documented dependencies and other interesting facts. scancode-toolkit-mini is a special build that does not come with pre-built binary dependencies by default. These are instead installed separately or with the extra_requires scancode-toolkit-mini[full]
Expand Down Expand Up @@ -59,7 +59,7 @@ install_requires =
chardet >= 3.0.0
click >= 6.7, !=7.0
colorama >= 0.3.9
commoncode >= 21.8.31
commoncode >= 30.0.0
debian-inspector >= 30.0.0
dparse >= 0.5.1
fasteners
Expand Down
4 changes: 2 additions & 2 deletions setup.cfg
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[metadata]
name = scancode-toolkit
version = 30.0.0
version = 30.0.1
license = Apache-2.0 AND CC-BY-4.0 AND LicenseRef-scancode-other-permissive AND LicenseRef-scancode-other-copyleft

description = ScanCode is a tool to scan code for license, copyright, package and their documented dependencies and other interesting facts.
Expand Down Expand Up @@ -59,7 +59,7 @@ install_requires =
chardet >= 3.0.0
click >= 6.7, !=7.0
colorama >= 0.3.9
commoncode >= 21.8.31
commoncode >= 30.0.0
debian-inspector >= 30.0.0
dparse >= 0.5.1
fasteners
Expand Down
4 changes: 2 additions & 2 deletions src/scancode_config.py
Original file line number Diff line number Diff line change
Expand Up @@ -77,10 +77,10 @@ def _create_dir(location):

# in case package is not installed or we do not have setutools/pkg_resources
# on hand fall back to this version
__version__ = '30.0.0'
__version__ = '30.0.1'

# used to warn user when the version is out of date
__release_date__ = datetime.datetime(2021, 9, 23)
__release_date__ = datetime.datetime(2021, 9, 24)

# See https://github.com/nexB/scancode-toolkit/issues/2653 for more information
# on the data format version
Expand Down