diff --git a/.github/workflows/scancode-release.yml b/.github/workflows/scancode-release.yml index 0d08d70097b..b80549d8944 100644 --- a/.github/workflows/scancode-release.yml +++ b/.github/workflows/scancode-release.yml @@ -457,12 +457,6 @@ jobs: name: source_app path: dist - - name: Download a single artifact macos_app for python 3.7 - uses: actions/download-artifact@v3 - with: - name: macos_app_py_3.7 - path: dist - - name: Download a single artifact macos_app for python 3.8 uses: actions/download-artifact@v3 with: @@ -487,10 +481,10 @@ jobs: name: macos_app_py_3.11 path: dist - - name: Download a single artifact linux_app for python 3.7 + - name: Download a single artifact macos_app for python 3.12 uses: actions/download-artifact@v3 with: - name: linux_app_py_3.7 + name: macos_app_py_3.12 path: dist - name: Download a single artifact linux_app for python 3.8 @@ -517,10 +511,10 @@ jobs: name: linux_app_py_3.11 path: dist - - name: Download a single artifact windows_app for python 3.7 + - name: Download a single artifact linux_app for python 3.12 uses: actions/download-artifact@v3 with: - name: windows_app_py_3.7 + name: linux_app_py_3.12 path: dist - name: Download a single artifact windows_app for python 3.8 @@ -547,6 +541,12 @@ jobs: name: windows_app_py_3.11 path: dist + - name: Download a single artifact windows_app for python 3.12 + uses: actions/download-artifact@v3 + with: + name: windows_app_py_3.12 + path: dist + - name: Mock GH release run: | ls -al dist @@ -573,7 +573,7 @@ jobs: strategy: fail-fast: true matrix: - dist_names: ["wheels-3.7", "wheels-3.8", "wheels-3.9", "wheels-3.10", "wheels-3.11", sdists] + dist_names: ["wheels-3.8", "wheels-3.9", "wheels-3.10", "wheels-3.11", "wheels-3.12", sdists] steps: - name: Set up Python @@ -592,6 +592,6 @@ jobs: ls -al dist - name: Publish distributions to PyPI - uses: pypa/gh-action-pypi-publish@master + uses: pypa/gh-action-pypi-publish@release/v1 with: password: ${{ secrets.PYPI_API_TOKEN }} diff --git a/INSTALL.rst b/INSTALL.rst index 0c5af85c68e..e3b8ab1f415 100644 --- a/INSTALL.rst +++ b/INSTALL.rst @@ -16,7 +16,7 @@ Prerequisites ------------- Before installing ScanCode make sure you have installed these prerequisites. -The main one is to have Python installed version 3.7, 3.8, 3.9 or 3.10 +The main one is to have Python installed version 3.8, 3.9, 3.10, 3.11 or 3.12 - For Linux(Ubuntu): ``sudo apt install python3.8-dev bzip2 xz-utils zlib1g libxml2-dev libxslt1-dev`` - For MacOS: Install Python 3.x from https://www.python.org/ diff --git a/README.rst b/README.rst index 14df607b47c..eca9654c3b2 100644 --- a/README.rst +++ b/README.rst @@ -140,7 +140,7 @@ Installation Before installing ScanCode make sure that you have installed the prerequisites properly. This means installing Python 3.8 for x86/64 architectures. -We support Python 3.8, 3.9, 3.10 and 3.11. +We support Python 3.8, 3.9, 3.10, 3.11 and 3.12. See `prerequisites `_ for detailed information on the support platforms and Python versions. diff --git a/docs/source/contribute/contrib_dev.rst b/docs/source/contribute/contrib_dev.rst index 2498bba26b7..9a6c5ef49e9 100644 --- a/docs/source/contribute/contrib_dev.rst +++ b/docs/source/contribute/contrib_dev.rst @@ -186,9 +186,9 @@ recursive dependencies. There are utility scripts in ``etc/release`` that can help with the dependencies management process in particular to build or update wheels with native code for -multiple OSes (Linux, macOS and Windows) and multiple Python versions (3.7+), +multiple OSes (Linux, macOS and Windows) and multiple Python versions (3.8+), which is not a completely simple operation (and requires eventually 12 wheels -and one source distribution to be published as we support 3 OSes and 4 Python +and one source distribution to be published as we support 3 OSes and 5 Python versions). diff --git a/docs/source/getting-started/install.rst b/docs/source/getting-started/install.rst index c3cceb10d89..d27f7f92854 100644 --- a/docs/source/getting-started/install.rst +++ b/docs/source/getting-started/install.rst @@ -39,7 +39,7 @@ For advanced usage and experienced users, you can also use any of these mode: Before Installing ----------------- -- ScanCode requires a Python version 3.7, 3.8, 3.9 or 3.10 and is +- ScanCode requires a Python version between 3.8 to 3.12 and is tested on Linux, macOS, and Windows. It should work fine on FreeBSD. .. _system_requirements: @@ -66,8 +66,8 @@ System Requirements Prerequisites ^^^^^^^^^^^^^ -ScanCode needs a Python 3.7+ interpreter; We support all Python versions from -3.7 to 3.10. The default version for the application archives is Python 3.8 +ScanCode needs a Python 3.8+ interpreter; We support all Python versions from +3.8 to 3.12. The default version for the application archives is Python 3.8 - **On Linux**: diff --git a/etc/scripts/utils_thirdparty.py b/etc/scripts/utils_thirdparty.py index 14c4dc2c3b8..7bb34650b3d 100755 --- a/etc/scripts/utils_thirdparty.py +++ b/etc/scripts/utils_thirdparty.py @@ -115,14 +115,14 @@ TRACE_ULTRA_DEEP = False # Supported environments -PYTHON_VERSIONS = "37", "38", "39", "310", "311" +PYTHON_VERSIONS = "38", "39", "310", "311", "312" PYTHON_DOT_VERSIONS_BY_VER = { - "37": "3.7", "38": "3.8", "39": "3.9", "310": "3.10", "311": "3.11", + "312": "3.12", } @@ -134,11 +134,11 @@ def get_python_dot_version(version): ABIS_BY_PYTHON_VERSION = { - "37": ["cp37", "cp37m", "abi3"], "38": ["cp38", "cp38m", "abi3"], "39": ["cp39", "cp39m", "abi3"], "310": ["cp310", "cp310m", "abi3"], "311": ["cp311", "cp311m", "abi3"], + "312": ["cp312", "cp312m", "abi3"], } PLATFORMS_BY_OS = { diff --git a/requirements-native.txt b/requirements-native.txt index 00531f5f092..f1f2b09b80e 100644 --- a/requirements-native.txt +++ b/requirements-native.txt @@ -1,6 +1,6 @@ -cffi==1.15.1 +cffi==1.16.0 intbitset==3.1.0 -lxml==4.9.4 -MarkupSafe==2.1.1 -pyahocorasick==2.0.0 -PyYAML==6.0 +lxml==5.1.0 +MarkupSafe==2.1.5 +pyahocorasick==2.1.0 +PyYAML==6.0.1 diff --git a/requirements.txt b/requirements.txt index 7b9b8f842e5..080442210b5 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,18 +1,19 @@ -attrs==22.1.0 +attrs==23.2.0 banal==1.0.6 -beautifulsoup4==4.11.1 +beautifulsoup4==4.12.3 binaryornot==0.4.4 +beartype==0.17.2 boolean.py==4.0 -certifi==2022.6.15 -cffi==1.15.1 +certifi==2024.2.2 +cffi==1.16.0 chardet==5.0.0 charset-normalizer==2.1.0 -click==8.1.3 +click==8.1.7 colorama==0.4.5 commoncode==31.0.3 construct==2.10.68 container-inspector==31.1.0 -cryptography==37.0.4 +cryptography==42.0.5 debian-inspector==31.1.0 dockerfile-parse==1.2.0 dparse2==0.7.0 @@ -32,14 +33,14 @@ intbitset==3.1.0 isodate==0.6.1 jaraco.functools==3.5.1 javaproperties==0.8.1 -Jinja2==3.1.2 +Jinja2==3.1.3 jsonstreams==0.6.0 -license-expression==30.1.1 -lxml==4.9.4 -MarkupSafe==2.1.2 +license-expression==30.3.0 +lxml==5.1.0 +MarkupSafe==2.1.5 more-itertools==8.13.0 normality==2.3.3 -packageurl-python==0.10.0 +packageurl-python==0.15.0 packaging==21.3 packvers==21.5 parameter-expansion-patched==0.3.1 @@ -51,26 +52,28 @@ pluggy==1.0.0 plugincode==32.0.0 ply==3.11 publicsuffix2==2.20191221 -pyahocorasick==2.0.0 +pyahocorasick==2.1.0 pycparser==2.21 pygmars==0.7.0 Pygments==2.13.0 -pymaven-patch==0.3.0 +pymaven-patch==0.3.2 pyparsing==3.0.9 pytz==2022.1 -PyYAML==6.0 +PyYAML==6.0.1 rdflib==6.2.0 -requests==2.28.1 +requests==2.31.0 saneyaml==0.6.0 +semantic-version==2.8.5 six==1.16.0 soupsieve==2.3.2.post1 -spdx-tools==0.8.1 +spdx-tools==0.8.2 text-unidecode==1.3 toml==0.10.2 typecode==30.0.1 typecode-libmagic==5.39.210531 typing-extensions==4.3.0 -urllib3==1.26.11 +uritools==4.0.2 +urllib3==2.2.1 urlpy==0.5 wcwidth==0.2.5 webencodings==0.5.1 diff --git a/setup-mini.cfg b/setup-mini.cfg index 389d414c296..d9487072a41 100644 --- a/setup-mini.cfg +++ b/setup-mini.cfg @@ -1,6 +1,6 @@ [metadata] name = scancode-toolkit-mini -version = 32.0.8 +version = 32.1.0 license = Apache-2.0 AND CC-BY-4.0 AND LicenseRef-scancode-other-permissive AND LicenseRef-scancode-other-copyleft # description must be on ONE line https://github.com/pypa/setuptools/issues/1390 @@ -17,11 +17,11 @@ classifiers = Intended Audience :: Developers Programming Language :: Python :: 3 Programming Language :: Python :: 3 :: Only - Programming Language :: Python :: 3.7 Programming Language :: Python :: 3.8 Programming Language :: Python :: 3.9 Programming Language :: Python :: 3.10 Programming Language :: Python :: 3.11 + Programming Language :: Python :: 3.12 Topic :: Software Development Topic :: Utilities @@ -60,7 +60,7 @@ zip_safe = false py_modules = scancode_config -python_requires = >=3.7 +python_requires = >=3.8 install_requires = attrs >= 18.1,!=20.1.0;python_version<'3.11' @@ -70,7 +70,7 @@ install_requires = chardet >= 3.0.0 click >= 6.7, !=7.0 colorama >= 0.3.9 - commoncode >= 31.0.2 + commoncode >= 31.0.3 container-inspector >= 31.0.0 debian-inspector >= 31.1.0 dparse2 >= 0.7.0 @@ -105,7 +105,7 @@ install_requires = pymaven_patch >= 0.2.8 requests >= 2.7.0 saneyaml >= 0.6.0 - spdx_tools == 0.8.1 + spdx_tools == 0.8.2 text_unidecode >= 1.0 toml >= 0.10.0 urlpy diff --git a/setup.cfg b/setup.cfg index b6c1bd2c075..01a05992e6b 100644 --- a/setup.cfg +++ b/setup.cfg @@ -1,6 +1,6 @@ [metadata] name = scancode-toolkit -version = 32.0.8 +version = 32.1.0 license = Apache-2.0 AND CC-BY-4.0 AND LicenseRef-scancode-other-permissive AND LicenseRef-scancode-other-copyleft # description must be on ONE line https://github.com/pypa/setuptools/issues/1390 @@ -17,11 +17,11 @@ classifiers = Intended Audience :: Developers Programming Language :: Python :: 3 Programming Language :: Python :: 3 :: Only - Programming Language :: Python :: 3.7 Programming Language :: Python :: 3.8 Programming Language :: Python :: 3.9 Programming Language :: Python :: 3.10 Programming Language :: Python :: 3.11 + Programming Language :: Python :: 3.12 Topic :: Software Development Topic :: Utilities @@ -60,7 +60,7 @@ zip_safe = false py_modules = scancode_config -python_requires = >=3.7 +python_requires = >=3.8 install_requires = attrs >= 18.1,!=20.1.0;python_version<'3.11' @@ -105,7 +105,7 @@ install_requires = pymaven_patch >= 0.2.8 requests >= 2.7.0 saneyaml >= 0.6.0 - spdx_tools == 0.8.1 + spdx_tools == 0.8.2 text_unidecode >= 1.0 toml >= 0.10.0 urlpy diff --git a/src/scancode_config.py b/src/scancode_config.py index ba4e5d6f5b1..d4506b5e755 100644 --- a/src/scancode_config.py +++ b/src/scancode_config.py @@ -132,12 +132,12 @@ def _create_dir(location): # 4. hardcoded This is the default, fallback version in case package is not installed or we # do not have a proper version otherwise. if not __version__: - __version__ = '32.0.8' + __version__ = '32.1.0' ####################### # used to warn user when the version is out of date # this is (year, month, day) -__release_date__ = datetime.datetime(2023, 10, 11) +__release_date__ = datetime.datetime(2024, 3, 22) # See https://github.com/nexB/scancode-toolkit/issues/2653 for more information # on the data format version diff --git a/tests/formattedcode/data/spdx/license_known/expected.tv b/tests/formattedcode/data/spdx/license_known/expected.tv index c44976e3c59..cedb74eff5b 100644 --- a/tests/formattedcode/data/spdx/license_known/expected.tv +++ b/tests/formattedcode/data/spdx/license_known/expected.tv @@ -16,7 +16,7 @@ SPDX License List: 3.23 PackageName: scan SPDXID: SPDXRef-001 PackageDownloadLocation: NOASSERTION -FilesAnalyzed: True +FilesAnalyzed: true PackageVerificationCode: 517c26f04b5a3edaaa0c17bf1a6571953209e209 PackageLicenseConcluded: NOASSERTION PackageLicenseInfoFromFiles: Apache-2.0 diff --git a/tests/formattedcode/data/spdx/license_known/expected_with_text.tv b/tests/formattedcode/data/spdx/license_known/expected_with_text.tv index c44976e3c59..cedb74eff5b 100644 --- a/tests/formattedcode/data/spdx/license_known/expected_with_text.tv +++ b/tests/formattedcode/data/spdx/license_known/expected_with_text.tv @@ -16,7 +16,7 @@ SPDX License List: 3.23 PackageName: scan SPDXID: SPDXRef-001 PackageDownloadLocation: NOASSERTION -FilesAnalyzed: True +FilesAnalyzed: true PackageVerificationCode: 517c26f04b5a3edaaa0c17bf1a6571953209e209 PackageLicenseConcluded: NOASSERTION PackageLicenseInfoFromFiles: Apache-2.0 diff --git a/tests/formattedcode/data/spdx/license_ref/expected.tv b/tests/formattedcode/data/spdx/license_ref/expected.tv index 65734879963..e524ae5ccdc 100644 --- a/tests/formattedcode/data/spdx/license_ref/expected.tv +++ b/tests/formattedcode/data/spdx/license_ref/expected.tv @@ -16,7 +16,7 @@ SPDX License List: 3.23 PackageName: scan SPDXID: SPDXRef-001 PackageDownloadLocation: NOASSERTION -FilesAnalyzed: True +FilesAnalyzed: true PackageVerificationCode: b49eeefd776fb76555378d07fd05d986a249a2b3 PackageLicenseConcluded: NOASSERTION PackageLicenseInfoFromFiles: Apache-2.0 diff --git a/tests/formattedcode/data/spdx/license_ref/expected_with_text.tv b/tests/formattedcode/data/spdx/license_ref/expected_with_text.tv index d9bbcce9510..ded6faaac34 100644 --- a/tests/formattedcode/data/spdx/license_ref/expected_with_text.tv +++ b/tests/formattedcode/data/spdx/license_ref/expected_with_text.tv @@ -16,7 +16,7 @@ SPDX License List: 3.23 PackageName: scan SPDXID: SPDXRef-001 PackageDownloadLocation: NOASSERTION -FilesAnalyzed: True +FilesAnalyzed: true PackageVerificationCode: b49eeefd776fb76555378d07fd05d986a249a2b3 PackageLicenseConcluded: NOASSERTION PackageLicenseInfoFromFiles: Apache-2.0 diff --git a/tests/formattedcode/data/spdx/simple/expected.tv b/tests/formattedcode/data/spdx/simple/expected.tv index 772dbc521b2..23e13188545 100644 --- a/tests/formattedcode/data/spdx/simple/expected.tv +++ b/tests/formattedcode/data/spdx/simple/expected.tv @@ -16,7 +16,7 @@ SPDX License List: 3.23 PackageName: simple SPDXID: SPDXRef-001 PackageDownloadLocation: NOASSERTION -FilesAnalyzed: True +FilesAnalyzed: true PackageVerificationCode: a83523bcfc10441aa94a575b88aa1d3269902485 PackageLicenseConcluded: NOASSERTION PackageLicenseInfoFromFiles: NONE diff --git a/tests/formattedcode/data/spdx/tree/expected.tv b/tests/formattedcode/data/spdx/tree/expected.tv index 023e4f159b4..97eb7ce0335 100644 --- a/tests/formattedcode/data/spdx/tree/expected.tv +++ b/tests/formattedcode/data/spdx/tree/expected.tv @@ -16,7 +16,7 @@ SPDX License List: 3.23 PackageName: scan SPDXID: SPDXRef-001 PackageDownloadLocation: NOASSERTION -FilesAnalyzed: True +FilesAnalyzed: true PackageVerificationCode: ed7a0c42e0411fe584d7c6d04105416593624be3 PackageLicenseConcluded: NOASSERTION PackageLicenseInfoFromFiles: NONE diff --git a/tests/formattedcode/data/spdx/unicode/expected.tv b/tests/formattedcode/data/spdx/unicode/expected.tv index df419d59681..08f42831fc7 100644 --- a/tests/formattedcode/data/spdx/unicode/expected.tv +++ b/tests/formattedcode/data/spdx/unicode/expected.tv @@ -16,7 +16,7 @@ SPDX License List: 3.23 PackageName: unicode SPDXID: SPDXRef-001 PackageDownloadLocation: NOASSERTION -FilesAnalyzed: True +FilesAnalyzed: true PackageVerificationCode: ce09fd939153fe02b82fefb764381ba40234e6ca PackageLicenseConcluded: NOASSERTION PackageLicenseInfoFromFiles: LicenseRef-scancode-agere-bsd