From ff0072c415d13999ce31c9d183e7e9ca4a9316d1 Mon Sep 17 00:00:00 2001 From: GitHub Date: Sat, 2 Dec 2023 20:35:29 +0000 Subject: [PATCH 1/3] MAINT: update pip constraints and pre-commit --- .pre-commit-config.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 069d7a0ca..0791c044a 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -39,7 +39,7 @@ repos: - id: trailing-whitespace - repo: https://github.com/ComPWA/repo-maintenance - rev: 0.1.5 + rev: 0.1.6 hooks: - id: check-dev-files args: From 20b9d946d7b8f5cc220ae668a1af804d2b58ffbb Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Sat, 2 Dec 2023 20:35:56 +0000 Subject: [PATCH 2/3] [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --- .pre-commit-config.yaml | 21 ++------------------- pyproject.toml | 41 +++++++++++++++++++++++------------------ 2 files changed, 25 insertions(+), 37 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 0791c044a..4a7159868 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -56,16 +56,6 @@ repos: - --additional-packages=IPython - --extras-require=doc,viz - - repo: https://github.com/nbQA-dev/nbQA - rev: 1.7.1 - hooks: - - id: nbqa-pyupgrade - args: - - --py37-plus - - id: nbqa-ruff - args: - - --fix - - repo: https://github.com/psf/black-pre-commit-mirror rev: 23.11.0 hooks: @@ -153,19 +143,12 @@ repos: hooks: - id: pyright - - repo: https://github.com/asottile/pyupgrade - rev: v3.15.0 - hooks: - - id: pyupgrade - args: - - --py37-plus - - repo: https://github.com/astral-sh/ruff-pre-commit rev: v0.1.6 hooks: - id: ruff - args: - - --fix + args: [--fix] + types_or: [python, pyi, jupyter] - repo: https://github.com/ComPWA/mirrors-taplo rev: v0.8.1 diff --git a/pyproject.toml b/pyproject.toml index 4c77f36e2..c0808d04b 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -88,10 +88,13 @@ format = [ "black", ] jupyter = [ + "isort", "jupyterlab", "jupyterlab-code-formatter", + "jupyterlab-git", "jupyterlab-lsp", "jupyterlab-myst", + "python-lsp-ruff", "python-lsp-server[rope]", 'ypy-websocket <0.8.3; python_version <"3.8.0"', ] @@ -220,24 +223,6 @@ module = ["pybtex.*"] ignore_missing_imports = true module = ["sphinx.*"] -[tool.nbqa.addopts] -ruff = [ - "--extend-ignore=B018", - "--extend-ignore=C408", - "--extend-ignore=C90", - "--extend-ignore=D", - "--extend-ignore=F404", - "--extend-ignore=N806", - "--extend-ignore=N816", - "--extend-ignore=PLR09", - "--extend-ignore=PLR2004", - "--extend-ignore=PLW0602", - "--extend-ignore=PLW0603", - "--extend-ignore=S301", # allow pickle - "--extend-ignore=TCH002", - "--line-length=85", -] - [tool.pyright] exclude = [ "**/.git", @@ -304,6 +289,7 @@ testpaths = [ [tool.ruff] extend-exclude = ["typings"] +extend-include = ["*.ipynb"] extend-select = [ "A", "B", @@ -363,6 +349,25 @@ task-tags = ["cspell"] known-third-party = ["sympy"] [tool.ruff.per-file-ignores] +"*.ipynb" = [ + "B018", + "C408", + "C90", + "D", + "E402", + "E703", + "F404", + "N806", + "N816", + "PLR09", + "PLR2004", + "PLW0602", + "PLW0603", + "S101", + "S301", + "T201", + "TCH00", +] "docs/*" = [ "E402", "INP001", From cb705c02df79fb0551025b1e2399a92a531ef182 Mon Sep 17 00:00:00 2001 From: GitHub Date: Sat, 2 Dec 2023 20:42:41 +0000 Subject: [PATCH 3/3] MAINT: update pip constraints and pre-commit --- .constraints/py3.10.txt | 10 ++++++++++ .constraints/py3.11.txt | 10 ++++++++++ .constraints/py3.12.txt | 10 ++++++++++ .constraints/py3.7.txt | 10 ++++++++++ .constraints/py3.8.txt | 10 ++++++++++ .constraints/py3.9.txt | 10 ++++++++++ 6 files changed, 60 insertions(+) diff --git a/.constraints/py3.10.txt b/.constraints/py3.10.txt index fef050933..197849042 100644 --- a/.constraints/py3.10.txt +++ b/.constraints/py3.10.txt @@ -18,6 +18,7 @@ beautifulsoup4==4.12.2 black==23.11.0 bleach==6.1.0 cachetools==5.3.2 +cattrs==23.2.3 certifi==2023.11.17 cffi==1.16.0 cfgv==3.4.0 @@ -42,6 +43,8 @@ fastjsonschema==2.19.0 filelock==3.13.1 fonttools==4.46.0 fqdn==1.5.1 +gitdb==4.0.11 +gitpython==3.1.40 gprof2dot==2022.7.29 graphviz==0.20.1 greenlet==3.0.1 @@ -57,6 +60,7 @@ ipython==8.18.1 ipython-genutils==0.2.0 ipywidgets==8.1.1 isoduration==20.11.0 +isort==5.12.0 jedi==0.19.1 jinja2==3.1.2 json5==0.9.14 @@ -69,9 +73,11 @@ jupyter-core==5.5.0 jupyter-events==0.9.0 jupyter-lsp==2.2.1 jupyter-server==2.11.1 +jupyter-server-mathjax==0.2.6 jupyter-server-terminals==0.4.4 jupyterlab==4.0.9 jupyterlab-code-formatter==2.2.1 +jupyterlab-git==0.50.0 jupyterlab-lsp==5.0.1 jupyterlab-myst==2.1.0 jupyterlab-pygments==0.3.0 @@ -80,6 +86,7 @@ jupyterlab-widgets==3.0.9 kiwisolver==1.4.5 latexcodec==2.0.1 livereload==2.6.3 +lsprotocol==2023.0.0 markdown-it-py==2.2.0 markupsafe==2.1.3 matplotlib==3.8.2 @@ -95,6 +102,7 @@ myst-nb==1.0.0 myst-parser==1.0.0 nbclient==0.6.8 nbconvert==7.11.0 +nbdime==4.0.1 nbformat==5.9.2 nbmake==1.4.6 nest-asyncio==1.5.8 @@ -132,6 +140,7 @@ python-constraint==1.4.0 python-dateutil==2.8.2 python-json-logger==2.0.7 python-lsp-jsonrpc==1.1.2 +python-lsp-ruff==2.0.0 python-lsp-server==1.9.0 pytoolconfig==1.2.6 pyyaml==6.0.1 @@ -147,6 +156,7 @@ rpds-py==0.13.2 ruff==0.1.6 send2trash==1.8.2 six==1.16.0 +smmap==5.0.1 sniffio==1.3.0 snowballstemmer==2.2.0 soupsieve==2.5 diff --git a/.constraints/py3.11.txt b/.constraints/py3.11.txt index e53b69226..187868c6a 100644 --- a/.constraints/py3.11.txt +++ b/.constraints/py3.11.txt @@ -18,6 +18,7 @@ beautifulsoup4==4.12.2 black==23.11.0 bleach==6.1.0 cachetools==5.3.2 +cattrs==23.2.3 certifi==2023.11.17 cffi==1.16.0 cfgv==3.4.0 @@ -41,6 +42,8 @@ fastjsonschema==2.19.0 filelock==3.13.1 fonttools==4.46.0 fqdn==1.5.1 +gitdb==4.0.11 +gitpython==3.1.40 gprof2dot==2022.7.29 graphviz==0.20.1 greenlet==3.0.1 @@ -56,6 +59,7 @@ ipython==8.18.1 ipython-genutils==0.2.0 ipywidgets==8.1.1 isoduration==20.11.0 +isort==5.12.0 jedi==0.19.1 jinja2==3.1.2 json5==0.9.14 @@ -68,9 +72,11 @@ jupyter-core==5.5.0 jupyter-events==0.9.0 jupyter-lsp==2.2.1 jupyter-server==2.11.1 +jupyter-server-mathjax==0.2.6 jupyter-server-terminals==0.4.4 jupyterlab==4.0.9 jupyterlab-code-formatter==2.2.1 +jupyterlab-git==0.50.0 jupyterlab-lsp==5.0.1 jupyterlab-myst==2.1.0 jupyterlab-pygments==0.3.0 @@ -79,6 +85,7 @@ jupyterlab-widgets==3.0.9 kiwisolver==1.4.5 latexcodec==2.0.1 livereload==2.6.3 +lsprotocol==2023.0.0 markdown-it-py==2.2.0 markupsafe==2.1.3 matplotlib==3.8.2 @@ -94,6 +101,7 @@ myst-nb==1.0.0 myst-parser==1.0.0 nbclient==0.6.8 nbconvert==7.11.0 +nbdime==4.0.1 nbformat==5.9.2 nbmake==1.4.6 nest-asyncio==1.5.8 @@ -131,6 +139,7 @@ python-constraint==1.4.0 python-dateutil==2.8.2 python-json-logger==2.0.7 python-lsp-jsonrpc==1.1.2 +python-lsp-ruff==2.0.0 python-lsp-server==1.9.0 pytoolconfig==1.2.6 pyyaml==6.0.1 @@ -146,6 +155,7 @@ rpds-py==0.13.2 ruff==0.1.6 send2trash==1.8.2 six==1.16.0 +smmap==5.0.1 sniffio==1.3.0 snowballstemmer==2.2.0 soupsieve==2.5 diff --git a/.constraints/py3.12.txt b/.constraints/py3.12.txt index 8f0481f4f..db92cd340 100644 --- a/.constraints/py3.12.txt +++ b/.constraints/py3.12.txt @@ -18,6 +18,7 @@ beautifulsoup4==4.12.2 black==23.11.0 bleach==6.1.0 cachetools==5.3.2 +cattrs==23.2.3 certifi==2023.11.17 cffi==1.16.0 cfgv==3.4.0 @@ -41,6 +42,8 @@ fastjsonschema==2.19.0 filelock==3.13.1 fonttools==4.46.0 fqdn==1.5.1 +gitdb==4.0.11 +gitpython==3.1.40 gprof2dot==2022.7.29 graphviz==0.20.1 greenlet==3.0.1 @@ -56,6 +59,7 @@ ipython==8.18.1 ipython-genutils==0.2.0 ipywidgets==8.1.1 isoduration==20.11.0 +isort==5.12.0 jedi==0.19.1 jinja2==3.1.2 json5==0.9.14 @@ -68,9 +72,11 @@ jupyter-core==5.5.0 jupyter-events==0.9.0 jupyter-lsp==2.2.1 jupyter-server==2.11.1 +jupyter-server-mathjax==0.2.6 jupyter-server-terminals==0.4.4 jupyterlab==4.0.9 jupyterlab-code-formatter==2.2.1 +jupyterlab-git==0.50.0 jupyterlab-lsp==5.0.1 jupyterlab-myst==2.1.0 jupyterlab-pygments==0.3.0 @@ -79,6 +85,7 @@ jupyterlab-widgets==3.0.9 kiwisolver==1.4.5 latexcodec==2.0.1 livereload==2.6.3 +lsprotocol==2023.0.0 markdown-it-py==2.2.0 markupsafe==2.1.3 matplotlib==3.8.2 @@ -94,6 +101,7 @@ myst-nb==1.0.0 myst-parser==1.0.0 nbclient==0.6.8 nbconvert==7.11.0 +nbdime==4.0.1 nbformat==5.9.2 nbmake==1.4.6 nest-asyncio==1.5.8 @@ -131,6 +139,7 @@ python-constraint==1.4.0 python-dateutil==2.8.2 python-json-logger==2.0.7 python-lsp-jsonrpc==1.1.2 +python-lsp-ruff==2.0.0 python-lsp-server==1.9.0 pytoolconfig==1.2.6 pyyaml==6.0.1 @@ -146,6 +155,7 @@ rpds-py==0.13.2 ruff==0.1.6 send2trash==1.8.2 six==1.16.0 +smmap==5.0.1 sniffio==1.3.0 snowballstemmer==2.2.0 soupsieve==2.5 diff --git a/.constraints/py3.7.txt b/.constraints/py3.7.txt index b70db5996..828076b16 100644 --- a/.constraints/py3.7.txt +++ b/.constraints/py3.7.txt @@ -20,6 +20,7 @@ black==23.3.0 bleach==6.0.0 cached-property==1.5.2 cachetools==5.3.2 +cattrs==23.1.2 certifi==2023.11.17 cffi==1.15.1 cfgv==3.3.1 @@ -43,6 +44,8 @@ fastjsonschema==2.19.0 filelock==3.12.2 fonttools==4.38.0 fqdn==1.5.1 +gitdb==4.0.11 +gitpython==3.1.40 gprof2dot==2022.7.29 graphviz==0.20.1 greenlet==3.0.1 @@ -59,6 +62,7 @@ ipython==7.34.0 ipython-genutils==0.2.0 ipywidgets==8.1.1 isoduration==20.11.0 +isort==5.11.5 jedi==0.18.2 jinja2==3.1.2 json5==0.9.14 @@ -71,10 +75,12 @@ jupyter-events==0.6.3 jupyter-lsp==1.5.1 jupyter-server==1.24.0 jupyter-server-fileid==0.9.0 +jupyter-server-mathjax==0.2.6 jupyter-server-ydoc==0.8.0 jupyter-ydoc==0.2.4 jupyterlab==3.6.6 jupyterlab-code-formatter==2.2.1 +jupyterlab-git==0.44.0 jupyterlab-lsp==3.10.2 jupyterlab-myst==1.2.0 jupyterlab-pygments==0.2.2 @@ -83,6 +89,7 @@ jupyterlab-widgets==3.0.9 kiwisolver==1.4.5 latexcodec==2.0.1 livereload==2.6.3 +lsprotocol==2023.0.0 markdown-it-py==2.2.0 markupsafe==2.1.3 matplotlib==3.5.3 @@ -99,6 +106,7 @@ myst-parser==0.18.1 nbclassic==1.0.0 nbclient==0.5.13 nbconvert==7.6.0 +nbdime==3.2.1 nbformat==5.8.0 nbmake==1.2.1 nest-asyncio==1.5.8 @@ -139,6 +147,7 @@ python-constraint==1.4.0 python-dateutil==2.8.2 python-json-logger==2.0.7 python-lsp-jsonrpc==1.0.0 +python-lsp-ruff==1.6.0 python-lsp-server==1.7.4 pytoolconfig==1.2.6 pytz==2023.3.post1 @@ -154,6 +163,7 @@ ruff==0.1.6 send2trash==1.8.2 singledispatchmethod==1.0 ; python_version < "3.8.0" six==1.16.0 +smmap==5.0.1 sniffio==1.3.0 snowballstemmer==2.2.0 soupsieve==2.4.1 diff --git a/.constraints/py3.8.txt b/.constraints/py3.8.txt index 6d7f55513..579a9cc51 100644 --- a/.constraints/py3.8.txt +++ b/.constraints/py3.8.txt @@ -19,6 +19,7 @@ beautifulsoup4==4.12.2 black==23.11.0 bleach==6.1.0 cachetools==5.3.2 +cattrs==23.2.3 certifi==2023.11.17 cffi==1.16.0 cfgv==3.4.0 @@ -43,6 +44,8 @@ fastjsonschema==2.19.0 filelock==3.13.1 fonttools==4.46.0 fqdn==1.5.1 +gitdb==4.0.11 +gitpython==3.1.40 gprof2dot==2022.7.29 graphviz==0.20.1 greenlet==3.0.1 @@ -59,6 +62,7 @@ ipython==8.12.3 ipython-genutils==0.2.0 ipywidgets==8.1.1 isoduration==20.11.0 +isort==5.12.0 jedi==0.19.1 jinja2==3.1.2 json5==0.9.14 @@ -71,9 +75,11 @@ jupyter-core==5.5.0 jupyter-events==0.9.0 jupyter-lsp==2.2.1 jupyter-server==2.11.1 +jupyter-server-mathjax==0.2.6 jupyter-server-terminals==0.4.4 jupyterlab==4.0.9 jupyterlab-code-formatter==2.2.1 +jupyterlab-git==0.50.0 jupyterlab-lsp==5.0.1 jupyterlab-myst==2.1.0 jupyterlab-pygments==0.3.0 @@ -82,6 +88,7 @@ jupyterlab-widgets==3.0.9 kiwisolver==1.4.5 latexcodec==2.0.1 livereload==2.6.3 +lsprotocol==2023.0.0 markdown-it-py==2.2.0 markupsafe==2.1.3 matplotlib==3.7.4 @@ -97,6 +104,7 @@ myst-nb==0.17.2 myst-parser==0.18.1 nbclient==0.6.8 nbconvert==7.11.0 +nbdime==4.0.1 nbformat==5.9.2 nbmake==1.4.6 nest-asyncio==1.5.8 @@ -136,6 +144,7 @@ python-constraint==1.4.0 python-dateutil==2.8.2 python-json-logger==2.0.7 python-lsp-jsonrpc==1.1.2 +python-lsp-ruff==2.0.0 python-lsp-server==1.9.0 pytoolconfig==1.2.6 pytz==2023.3.post1 @@ -152,6 +161,7 @@ rpds-py==0.13.2 ruff==0.1.6 send2trash==1.8.2 six==1.16.0 +smmap==5.0.1 sniffio==1.3.0 snowballstemmer==2.2.0 soupsieve==2.5 diff --git a/.constraints/py3.9.txt b/.constraints/py3.9.txt index bfc6af8e2..558cba688 100644 --- a/.constraints/py3.9.txt +++ b/.constraints/py3.9.txt @@ -18,6 +18,7 @@ beautifulsoup4==4.12.2 black==23.11.0 bleach==6.1.0 cachetools==5.3.2 +cattrs==23.2.3 certifi==2023.11.17 cffi==1.16.0 cfgv==3.4.0 @@ -42,6 +43,8 @@ fastjsonschema==2.19.0 filelock==3.13.1 fonttools==4.46.0 fqdn==1.5.1 +gitdb==4.0.11 +gitpython==3.1.40 gprof2dot==2022.7.29 graphviz==0.20.1 greenlet==3.0.1 @@ -58,6 +61,7 @@ ipython==8.18.1 ipython-genutils==0.2.0 ipywidgets==8.1.1 isoduration==20.11.0 +isort==5.12.0 jedi==0.19.1 jinja2==3.1.2 json5==0.9.14 @@ -70,9 +74,11 @@ jupyter-core==5.5.0 jupyter-events==0.9.0 jupyter-lsp==2.2.1 jupyter-server==2.11.1 +jupyter-server-mathjax==0.2.6 jupyter-server-terminals==0.4.4 jupyterlab==4.0.9 jupyterlab-code-formatter==2.2.1 +jupyterlab-git==0.50.0 jupyterlab-lsp==5.0.1 jupyterlab-myst==2.1.0 jupyterlab-pygments==0.3.0 @@ -81,6 +87,7 @@ jupyterlab-widgets==3.0.9 kiwisolver==1.4.5 latexcodec==2.0.1 livereload==2.6.3 +lsprotocol==2023.0.0 markdown-it-py==2.2.0 markupsafe==2.1.3 matplotlib==3.8.2 @@ -96,6 +103,7 @@ myst-nb==1.0.0 myst-parser==1.0.0 nbclient==0.6.8 nbconvert==7.11.0 +nbdime==4.0.1 nbformat==5.9.2 nbmake==1.4.6 nest-asyncio==1.5.8 @@ -133,6 +141,7 @@ python-constraint==1.4.0 python-dateutil==2.8.2 python-json-logger==2.0.7 python-lsp-jsonrpc==1.1.2 +python-lsp-ruff==2.0.0 python-lsp-server==1.9.0 pytoolconfig==1.2.6 pyyaml==6.0.1 @@ -148,6 +157,7 @@ rpds-py==0.13.2 ruff==0.1.6 send2trash==1.8.2 six==1.16.0 +smmap==5.0.1 sniffio==1.3.0 snowballstemmer==2.2.0 soupsieve==2.5