From 893b33442f24f0c11c4dcdeaaddc5905a10f4d44 Mon Sep 17 00:00:00 2001 From: Carlos Venegas Date: Mon, 2 Oct 2023 22:18:53 +0200 Subject: [PATCH] Fix lint error --- .github/workflows/Publish.yml | 4 ++-- .github/workflows/build.yml | 2 +- apio/util.py | 5 ++--- pyproject.toml | 4 ++-- tox.ini | 2 +- 5 files changed, 8 insertions(+), 9 deletions(-) diff --git a/.github/workflows/Publish.yml b/.github/workflows/Publish.yml index 7c7adc85..29dec89e 100644 --- a/.github/workflows/Publish.yml +++ b/.github/workflows/Publish.yml @@ -18,7 +18,7 @@ jobs: - name: Set up Python uses: actions/setup-python@v4 with: - python-version: "3.8" + python-version: "3.9" # -- Install all the dependencies needed - name: Install dependencies @@ -31,4 +31,4 @@ jobs: FLIT_USERNAME: ${{ secrets.PYPI_USERNAME }} FLIT_PASSWORD: ${{ secrets.PYPI_PASSWORD }} run: | - make publish \ No newline at end of file + make publish diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 31b9f42c..15cd4f6a 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -9,7 +9,7 @@ jobs: runs-on: ubuntu-22.04 strategy: matrix: - python-version: [3.8] + python-version: [3.9] steps: - name: Checkout sources diff --git a/apio/util.py b/apio/util.py index 2c908514..668cd75b 100644 --- a/apio/util.py +++ b/apio/util.py @@ -700,12 +700,11 @@ def decorate(*args, **kwargs): exit_code = 1 try: exit_code = function(*args, **kwargs) + except Exception as exc: if str(exc): click.secho("Error: " + str(exc), fg="red") - - finally: - return exit_code + return exit_code return decorate diff --git a/pyproject.toml b/pyproject.toml index 0dad4c87..e601124d 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -14,7 +14,7 @@ classifiers=[ 'License :: OSI Approved :: GNU General Public License v2 (GPLv2)', 'Programming Language :: Python'] description-file = "README.md" -requires-python = ">=3.7" +requires-python = ">=3.9" requires = [ 'click==8.1.3', 'semantic_version==2.9.0', @@ -41,7 +41,7 @@ apio = "apio.__main__:cli" [tool.black] line-length = 79 -target-version = ['py38'] +target-version = ['py39'] [tool.pylint.messages_control] disable = [ diff --git a/tox.ini b/tox.ini index bce22f14..ff248000 100644 --- a/tox.ini +++ b/tox.ini @@ -1,6 +1,6 @@ [tox] isolated_build = True -envlist = py38 +envlist = py39 [testenv] deps =