diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 4e74561..ec6957a 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -9,7 +9,7 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - python-version: [3.7, 3.8, 3.9, "3.10"] + python-version: [3.8, 3.9, "3.10", "3.11"] steps: - uses: actions/checkout@v3 diff --git a/.pylintrc b/.pylintrc index c3aa40b..156c7ee 100644 --- a/.pylintrc +++ b/.pylintrc @@ -2,7 +2,7 @@ init-hook='import sys; sys.path.append("rplugin/python3")' [MESSAGES CONTROL] -disable=E1101,W0511,W0612,W0613,W0212,W0221,W0703,W0622,W1113,C,R +disable=E1101,W0511,W0612,W0613,W0212,W0221,W0703,W0622,W1113,W1514,C,R [BASIC] argument-rgx=[a-z_][a-z0-9_]{0,30}$ diff --git a/requirements_test.txt b/requirements_test.txt index 3b4052c..1525eaf 100644 --- a/requirements_test.txt +++ b/requirements_test.txt @@ -4,7 +4,7 @@ gkeepapi isort keyring mypy -pylint==2.9.5 +pylint==2.17.4 pynvim pytest pytest-cov diff --git a/rplugin/python3/gkeep/modal/layout.py b/rplugin/python3/gkeep/modal/layout.py index 2ea5167..ab01b2c 100644 --- a/rplugin/python3/gkeep/modal/layout.py +++ b/rplugin/python3/gkeep/modal/layout.py @@ -104,7 +104,7 @@ def open_win( ) if align is not None: if relative == "cursor": - raise Exception("Align requires relative = win/editor") + raise ValueError("Align requires relative = win/editor") anchor, row, col = calc_alignment( align, width, height, total_width, total_height ) diff --git a/rplugin/python3/gkeep/thread_util.py b/rplugin/python3/gkeep/thread_util.py index e91f393..e495cb7 100644 --- a/rplugin/python3/gkeep/thread_util.py +++ b/rplugin/python3/gkeep/thread_util.py @@ -24,7 +24,7 @@ def w(*args, **kwargs): # type: ignore @wraps(func) def w(*args, **kwargs): # type: ignore[no-untyped-def] if kwargs: - raise Exception( + raise ValueError( "Cannot use keyword arguments for @background function with max_waiting" ) with countlock: diff --git a/tox.ini b/tox.ini index 68a5a45..e544252 100644 --- a/tox.ini +++ b/tox.ini @@ -1,5 +1,5 @@ [tox] -envlist = py37, py38, py39, py310, lint +envlist = py38, py39, py310, py311, lint isolated_build = true skipsdist = true @@ -27,7 +27,7 @@ commands = [gh-actions] python = - 3.7: py37 3.8: py38 3.9: py39, lint 3.10: py310 + 3.11: py311