From fc08112235cf905aec63c808a71b51653fbba310 Mon Sep 17 00:00:00 2001 From: Patrick Lehmann Date: Sun, 5 Oct 2025 15:14:39 +0200 Subject: [PATCH] Added parameters to enable bandit and pylint checks. --- .github/workflows/CompletePipeline.yml | 13 ++++++++++++- dist/requirements.txt | 2 +- doc/index.rst | 2 +- doc/requirements.txt | 6 +++--- myPackage/__init__.py | 1 + pyproject.toml | 3 ++- requirements.txt | 2 +- 7 files changed, 21 insertions(+), 8 deletions(-) diff --git a/.github/workflows/CompletePipeline.yml b/.github/workflows/CompletePipeline.yml index bd07107..b7cecf0 100644 --- a/.github/workflows/CompletePipeline.yml +++ b/.github/workflows/CompletePipeline.yml @@ -93,6 +93,16 @@ on: required: false default: 'windows-arm:pypy-3.10 windows-arm:pypy-3.11' type: string + bandit: + description: 'Run Static Application Security Testing (SAST) using Bandit.' + required: false + default: 'false' + type: string + pylint: + description: 'Run Python linting using pylint.' + required: false + default: 'false' + type: string codecov: description: 'Publish merged coverage and unittest reports to Codecov.' required: false @@ -205,6 +215,8 @@ jobs: with: python_version: ${{ needs.UnitTestingParams.outputs.python_version }} package_directory: ${{ needs.UnitTestingParams.outputs.package_directory }} + bandit: ${{ inputs.bandit }} + pylint: ${{ inputs.pylint }} artifact: CodeQuality DocCoverage: @@ -219,7 +231,6 @@ jobs: uses: pyTooling/Actions/.github/workflows/Package.yml@dev needs: - UnitTestingParams -# - UnitTesting with: python_version: ${{ needs.UnitTestingParams.outputs.python_version }} artifact: ${{ fromJson(needs.UnitTestingParams.outputs.artifact_names).package_all }} diff --git a/dist/requirements.txt b/dist/requirements.txt index 778498a..cacbc6f 100644 --- a/dist/requirements.txt +++ b/dist/requirements.txt @@ -1,2 +1,2 @@ wheel ~= 0.45 -twine ~= 6.1 +twine ~= 6.2 diff --git a/doc/index.rst b/doc/index.rst index eb1c3b2..0242c18 100644 --- a/doc/index.rst +++ b/doc/index.rst @@ -164,7 +164,7 @@ Example Pipelines .. code-block:: toml [build-system] - requires = ["setuptools >= 80.0", "wheel ~= 0.45", "pyTooling ~= 8.5"] + requires = ["setuptools >= 80.0", "wheel ~= 0.45", "pyTooling ~= 8.7"] build-backend = "setuptools.build_meta" [tool.mypy] diff --git a/doc/requirements.txt b/doc/requirements.txt index 709b41b..63b74c1 100644 --- a/doc/requirements.txt +++ b/doc/requirements.txt @@ -1,6 +1,6 @@ -r ../requirements.txt -pyTooling ~= 8.5 +pyTooling ~= 8.7 # Enforce latest version on ReadTheDocs sphinx ~= 8.2 @@ -13,7 +13,7 @@ sphinx_rtd_theme ~= 3.0 # Sphinx Extenstions sphinxcontrib-mermaid ~= 1.0 autoapi >= 2.0.1 -sphinx_design ~= 0.6.1 -sphinx-copybutton >= 0.5.2 +sphinx_design ~= 0.6 +sphinx-copybutton >= 0.5 sphinx_autodoc_typehints ~= 3.2 sphinx_reports ~= 0.9 diff --git a/myPackage/__init__.py b/myPackage/__init__.py index 9ea7328..e545d62 100644 --- a/myPackage/__init__.py +++ b/myPackage/__init__.py @@ -40,6 +40,7 @@ __version__ = "0.4.5" __keywords__ = ["GitHub Actions"] __issue_tracker__ = "https://GitHub.com/pyTooling/Actions/issues" +from pickle import dumps from subprocess import check_call from pyTooling.Decorators import export, readonly diff --git a/pyproject.toml b/pyproject.toml index 6388d1c..8108040 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -2,13 +2,14 @@ requires = [ "setuptools >= 80.0", "wheel ~= 0.45", - "pyTooling ~= 8.5" + "pyTooling ~= 8.7" ] build-backend = "setuptools.build_meta" [tool.pylint.format] indent-string="\t" max-line-length = 120 +ignore-long-lines = "^.{0,110}#: .*" [tool.pylint.basic] argument-naming-style = "camelCase" diff --git a/requirements.txt b/requirements.txt index 3781d6d..4fcd219 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1 +1 @@ -pyTooling ~= 8.5 +pyTooling ~= 8.7