From 61926579965ff4ac6b6b49a10b1f6d1b05ccc733 Mon Sep 17 00:00:00 2001 From: tdruez <489057+tdruez@users.noreply.github.com> Date: Wed, 22 May 2024 18:36:12 +0400 Subject: [PATCH] Release v34.5.0 (#1246) Signed-off-by: tdruez --- CHANGELOG.rst | 4 ++-- scancodeio/__init__.py | 2 +- scanpipe/pipes/strings.py | 6 ++++-- scanpipe/pipes/symbols.py | 6 ++++-- setup.cfg | 10 +++++----- 5 files changed, 16 insertions(+), 12 deletions(-) diff --git a/CHANGELOG.rst b/CHANGELOG.rst index 59ae6360d..c35199b24 100644 --- a/CHANGELOG.rst +++ b/CHANGELOG.rst @@ -1,7 +1,7 @@ Changelog ========= -v34.5.0 (unreleased) +v34.5.0 (2024-05-22) -------------------- - Display the current path location in the "Codebase" panel as a navigation breadcrumbs. @@ -17,7 +17,7 @@ v34.5.0 (unreleased) - Workaround an issue with the cyclonedx-python-lib that does not allow to load SBOMs that contains properties with no values. - Also, a few fixes pre-validation are applyed before deserializing thr SBOM for + Also, a few fixes pre-validation are applied before deserializing thr SBOM for maximum compatibility. https://github.com/nexB/scancode.io/issues/1185 https://github.com/nexB/scancode.io/issues/1230 diff --git a/scancodeio/__init__.py b/scancodeio/__init__.py index 0fbaa7396..1f311612b 100644 --- a/scancodeio/__init__.py +++ b/scancodeio/__init__.py @@ -28,7 +28,7 @@ import git -VERSION = "34.4.0" +VERSION = "34.5.0" PROJECT_DIR = Path(__file__).resolve().parent ROOT_DIR = PROJECT_DIR.parent diff --git a/scanpipe/pipes/strings.py b/scanpipe/pipes/strings.py index bca608501..2d58c616e 100644 --- a/scanpipe/pipes/strings.py +++ b/scanpipe/pipes/strings.py @@ -20,8 +20,6 @@ # ScanCode.io is a free software code scanning tool from nexB Inc. and others. # Visit https://github.com/nexB/scancode.io for support and download. -from source_inspector import strings_xgettext - from scanpipe.pipes import LoopProgress @@ -34,6 +32,8 @@ def collect_and_store_resource_strings(project, logger=None): Collect source strings from codebase files using xgettext and store them in the extra data field. """ + from source_inspector import strings_xgettext + if not strings_xgettext.is_xgettext_installed(): raise XgettextNotFound( "``xgettext`` not found. Install ``gettext`` to use this pipeline." @@ -61,6 +61,8 @@ def _collect_and_store_resource_strings(resource): Collect strings from a resource using xgettext and store them in the extra data field. """ + from source_inspector import strings_xgettext + result = strings_xgettext.collect_strings(resource.location) strings = [item["string"] for item in result if "string" in item] resource.update_extra_data({"source_strings": strings}) diff --git a/scanpipe/pipes/symbols.py b/scanpipe/pipes/symbols.py index 967b9db90..4ef2724f6 100644 --- a/scanpipe/pipes/symbols.py +++ b/scanpipe/pipes/symbols.py @@ -22,8 +22,6 @@ from django.db.models import Q -from source_inspector import symbols_ctags - from scanpipe.pipes import LoopProgress @@ -36,6 +34,8 @@ def collect_and_store_resource_symbols_ctags(project, logger=None): Collect symbols from codebase files using Ctags and store them in the extra data field. """ + from source_inspector import symbols_ctags + if not symbols_ctags.is_ctags_installed(): raise UniversalCtagsNotFound( "``Universal Ctags`` not found." @@ -64,6 +64,8 @@ def _collect_and_store_resource_symbols_ctags(resource): Collect symbols from a resource using Ctags and store them in the extra data field. """ + from source_inspector import symbols_ctags + symbols = symbols_ctags.collect_symbols(resource.location) tags = [symbol["name"] for symbol in symbols if "name" in symbol] resource.update_extra_data({"source_symbols": tags}) diff --git a/setup.cfg b/setup.cfg index 5e593b3cc..327d81276 100644 --- a/setup.cfg +++ b/setup.cfg @@ -1,6 +1,6 @@ [metadata] name = scancodeio -version = 34.4.0 +version = 34.5.0 license = Apache-2.0 description = Automate software composition analysis pipelines long_description = file:README.rst @@ -50,7 +50,7 @@ include_package_data = true zip_safe = false install_requires = importlib-metadata==7.1.0 - setuptools==69.5.1 + setuptools==70.0.0 # Django related Django==5.0.6 django-environ==0.11.2 @@ -86,7 +86,7 @@ install_requires = # Utilities XlsxWriter==3.2.0 openpyxl==3.1.2 - requests==2.31.0 + requests==2.32.2 gitpython==3.1.43 # Profiling pyinstrument==4.6.2 @@ -122,7 +122,7 @@ dev = sphinxcontrib-django==2.5 # Release bumpver==2023.1129 - twine==5.0.0 + twine==5.1.0 [options.entry_points] console_scripts = @@ -166,7 +166,7 @@ ignore = D1,D203,D205,D212,D400,D415 [bumpver] version_pattern = "MAJOR.MINOR.PATCH" -current_version = "34.4.0" +current_version = "34.5.0" [bumpver:file_patterns] setup.cfg =