diff --git a/.codeclimate.yml b/.codeclimate.yml deleted file mode 100644 index b8edca9..0000000 --- a/.codeclimate.yml +++ /dev/null @@ -1,32 +0,0 @@ -version: "2" -checks: - argument-count: - config: - threshold: 4 - complex-logic: - config: - threshold: 4 - file-lines: - config: - threshold: 250 - method-complexity: - config: - threshold: 5 - method-count: - config: - threshold: 20 - method-lines: - config: - threshold: 25 - nested-control-flow: - config: - threshold: 4 - return-statements: - config: - threshold: 4 - similar-code: - config: - threshold: # language-specific defaults. an override will affect all languages. - identical-code: - config: - threshold: # language-specific defaults. an override will affect all languages. diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 1a3fbce..6cd8d60 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -47,47 +47,47 @@ jobs: echo "::error:: News file missing (See CONTRIBUTING.md guide for details)." - generate-docs: - name: Build Documentation - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - - uses: actions/setup-python@v5 - with: - python-version: ${{ env.python_version}} - - name: Determine dependencies - # Note - # The below code generates a pip requirements file from the pipenv development requirements (also obtaining the - # normal dependencies from setup.py). - # This code also forces the system to install latest tools as the ones present on the CI system may be too old - # for the process to go through properly. - # FIXME upgrade pipenv when https://github.com/pypa/pipenv/issues/4430 is actually fixed - run: | - python -m pip install --upgrade pip wheel setuptools - python -m pip install pipenv==${{ env.pipenv_version }} - echo "Locking dependencies" - python -m pipenv lock - python -m pipenv requirements > dev-requirements.txt - - uses: FranzDiebold/github-env-vars-action@v2 - - name: Load Python Dependencies from cache - uses: actions/cache@v4 - with: - path: ${{ env.python_cache_ubuntu_path }} - key: linux-pip-3-continuous-delivery-scripts - - name: Install dependencies - # Note - # As a virtual machine is already being used, pipenv - # is superfluous and eliminating pipenv in CI reduces overhead and reduce complexity, while retaining a single - # location for development dependencies. - run: | - python -m pip install -r dev-requirements.txt - python -m pip list - - name: Generate Documentation - run: | - cd-generate-docs --output_dir $(cd-get-config --key DOCUMENTATION_PRODUCTION_OUTPUT_PATH) - - name: Add copyright/licence notice. - run: | - cd-license-files + # generate-docs: + # name: Build Documentation + # runs-on: ubuntu-latest + # steps: + # - uses: actions/checkout@v4 + # - uses: actions/setup-python@v5 + # with: + # python-version: ${{ env.python_version}} + # - name: Determine dependencies + # # Note + # # The below code generates a pip requirements file from the pipenv development requirements (also obtaining the + # # normal dependencies from setup.py). + # # This code also forces the system to install latest tools as the ones present on the CI system may be too old + # # for the process to go through properly. + # # FIXME upgrade pipenv when https://github.com/pypa/pipenv/issues/4430 is actually fixed + # run: | + # python -m pip install --upgrade pip wheel setuptools + # python -m pip install pipenv==${{ env.pipenv_version }} + # echo "Locking dependencies" + # python -m pipenv lock + # python -m pipenv requirements > dev-requirements.txt + # - uses: FranzDiebold/github-env-vars-action@v2 + # - name: Load Python Dependencies from cache + # uses: actions/cache@v4 + # with: + # path: ${{ env.python_cache_ubuntu_path }} + # key: linux-pip-3-continuous-delivery-scripts + # - name: Install dependencies + # # Note + # # As a virtual machine is already being used, pipenv + # # is superfluous and eliminating pipenv in CI reduces overhead and reduce complexity, while retaining a single + # # location for development dependencies. + # run: | + # python -m pip install -r dev-requirements.txt + # python -m pip list + # - name: Generate Documentation + # run: | + # cd-generate-docs --output_dir $(cd-get-config --key DOCUMENTATION_PRODUCTION_OUTPUT_PATH) + # - name: Add copyright/licence notice. + # run: | + # cd-license-files tpip: name: Report licences in use (SPDX) diff --git a/DEVELOPMENT.md b/DEVELOPMENT.md index fbda815..5a586ed 100644 --- a/DEVELOPMENT.md +++ b/DEVELOPMENT.md @@ -133,18 +133,6 @@ Type hints should be used in the code wherever possible. Since the documentation shows the function signatures with the type hints there is no need to include additional type information in the docstrings. - -## Code Climate - -Code Climate is integrated with our GitHub flow. Failing the configured rules will yield a pull request not mergeable. - -If you prefer to view the Code Climate report on your machine, prior to sending a pull request, you can use the [cli provided by Code Climate](https://docs.codeclimate.com/docs/command-line-interface). - -Plugins for various tools are also available: - - [Atom](https://docs.codeclimate.com/docs/code-climate-atom-package) - - [PyCharm](https://plugins.jetbrains.com/plugin/13306-code-cleaner-with-code-climate-cli) - - [Vim](https://docs.codeclimate.com/docs/vim-plugin) - # Dependency upgrades For dependency upgrades, dependabot is relied upon and news files are auto-generated in order to document such change. Nonetheless, due to a change in [GitHub actions](https://github.blog/changelog/2021-02-19-github-actions-workflows-triggered-by-dependabot-prs-will-run-with-read-only-permissions), secrets are not available in the build triggered by the pull request unless they are [re-run manually](https://docs.github.com/en/code-security/supply-chain-security/keeping-your-dependencies-updated-automatically/automating-dependabot-with-github-actions#manually-re-running-a-workflow). So please re-run every dependabot PR CI jobs. @@ -192,4 +180,4 @@ To flag individual false positives add comment `# pragma: allowlist secret` to l To add all suspected secrets in the repository (excluding ones with an allow secret comment), run `detect-secrets scan --all-files --exclude-files 'Pipfile\.lock$' --exclude-files '.*\.html$' --exclude-files '.*\.properties$' --exclude-files 'ci.yml' --exclude-files '\.git' --exclude-files '.*_version.py' > .secrets.baseline` -If on Windows: then change the encoding of the .secrets.baseline file to UTF-8 then convert all `\` to `/` in the .secrets.baseline file \ No newline at end of file +If on Windows: then change the encoding of the .secrets.baseline file to UTF-8 then convert all `\` to `/` in the .secrets.baseline file diff --git a/README.md b/README.md index 6298507..9e29ba0 100644 --- a/README.md +++ b/README.md @@ -16,9 +16,6 @@ SPDX-License-Identifier: Apache-2.0 [![Build Status](https://github.com/ARMmbed/continuous-delivery-scripts/actions/workflows/ci.yml/badge.svg)](https://github.com/ARMmbed/continuous-delivery-scripts/actions/workflows/ci.yml) -[![Test Coverage](https://codecov.io/gh/ARMmbed/continuous-delivery-scripts/branch/main/graph/badge.svg?token=EAW9owYyjW)](https://codecov.io/gh/ARMmbed/continuous-delivery-scripts) -[![Maintainability](https://api.codeclimate.com/v1/badges/41301e959f22986b7b2b/maintainability)](https://codeclimate.com/github/ARMmbed/continuous-delivery-scripts/maintainability) - ## Overview Project initially forked from [ARMmbed/mbed-tools-ci-scripts](https://github.com/ARMmbed/continuous-delivery-scripts) but modified so that it can be used for any projects and any languages. diff --git a/news/20250627104347.misc b/news/20250627104347.misc new file mode 100644 index 0000000..f88f090 --- /dev/null +++ b/news/20250627104347.misc @@ -0,0 +1 @@ +♻️ Remove codeclimate file and references diff --git a/pyproject.toml b/pyproject.toml index b0a4cc3..0e6caf9 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -56,6 +56,8 @@ jaraco-context="MIT" importlib_metadata="Apache-2.0" docutils="BSD-3-Clause" backports-tarfile="MIT" +Markdown="BSD-3-Clause" +id="Apache-2.0" diff --git a/tests/packaging/fixtures/PKG-INFO b/tests/packaging/fixtures/PKG-INFO index 74ee69c..32262a4 100644 --- a/tests/packaging/fixtures/PKG-INFO +++ b/tests/packaging/fixtures/PKG-INFO @@ -16,8 +16,6 @@ Description: # Mbed Tools CI Scripts [![License](https://img.shields.io/badge/License-Apache%202.0-blue.svg)](https://github.com/ARMmbed/mbed-tools-ci-scripts/blob/master/LICENSE) [![Build Status](https://dev.azure.com/mbed-tools/mbed-tools-ci-scripts/_apis/build/status/Build%20and%20Release?branchName=master)](https://dev.azure.com/mbed-tools/mbed-tools-ci/_build/latest?definitionId=3&branchName=master) - [![Test Coverage](https://codecov.io/gh/ARMmbed/mbed-tools-ci-scripts/branch/master/graph/badge.svg)](https://codecov.io/gh/ARMmbed/mbed-tools-ci-scripts) - [![Maintainability](https://api.codeclimate.com/v1/badges/41301e959f22986b7b2b/maintainability)](https://codeclimate.com/github/ARMmbed/mbed-tools-ci-scripts/maintainability) ## Overview