From a051fcacd4ce418464efbf26ed1dc2c1495196ac Mon Sep 17 00:00:00 2001 From: GitHub Date: Sat, 9 Dec 2023 12:06:22 +0000 Subject: [PATCH 01/20] MAINT: update pip constraints and pre-commit --- .constraints/.gitignore | 1 + .constraints/py3.10.txt | 108 ++++++++++++++++++++-------------------- .constraints/py3.11.txt | 106 +++++++++++++++++++-------------------- .constraints/py3.7.txt | 40 +++++++-------- .constraints/py3.8.txt | 98 ++++++++++++++++++------------------ .constraints/py3.9.txt | 108 ++++++++++++++++++++-------------------- .pre-commit-config.yaml | 14 +++--- 7 files changed, 238 insertions(+), 237 deletions(-) create mode 100644 .constraints/.gitignore diff --git a/.constraints/.gitignore b/.constraints/.gitignore new file mode 100644 index 00000000..36a07ad0 --- /dev/null +++ b/.constraints/.gitignore @@ -0,0 +1 @@ +!py3.*.txt diff --git a/.constraints/py3.10.txt b/.constraints/py3.10.txt index 5dab7544..4107d846 100644 --- a/.constraints/py3.10.txt +++ b/.constraints/py3.10.txt @@ -7,7 +7,7 @@ accessible-pygments==0.0.4 alabaster==0.7.13 annotated-types==0.6.0 -anyio==4.0.0 +anyio==4.1.0 argon2-cffi==23.1.0 argon2-cffi-bindings==21.2.0 arrow==1.3.0 @@ -19,7 +19,7 @@ beautifulsoup4==4.12.2 black==23.11.0 bleach==6.1.0 cachetools==5.3.2 -certifi==2023.7.22 +certifi==2023.11.17 cffi==1.16.0 cfgv==3.4.0 chardet==5.2.0 @@ -29,7 +29,7 @@ colorama==0.4.6 comm==0.2.0 contourpy==1.2.0 coverage==7.3.2 -cryptography==41.0.5 +cryptography==41.0.7 cycler==0.12.1 dataproperty==1.0.1 debugpy==1.8.0 @@ -39,65 +39,65 @@ deprecated==1.2.14 distlib==0.3.7 docstring-to-markdown==0.13 docutils==0.17.1 -dominate==2.8.0 -exceptiongroup==1.1.3 +dominate==2.9.0 +exceptiongroup==1.2.0 execnet==2.0.2 executing==2.0.1 -fastjsonschema==2.18.1 +fastjsonschema==2.19.0 feynman==2.1.0 filelock==3.13.1 -fonttools==4.44.0 +fonttools==4.46.0 fqdn==1.5.1 -greenlet==3.0.1 -identify==2.5.31 -idna==3.4 +greenlet==3.0.2 +identify==2.5.33 +idna==3.6 imagesize==1.4.1 -importlib-metadata==6.8.0 +importlib-metadata==7.0.0 iniconfig==2.0.0 -ipykernel==6.26.0 -ipython==8.17.2 +ipykernel==6.27.1 +ipython==8.18.1 ipywidgets==8.1.1 isoduration==20.11.0 jedi==0.19.1 jinja2==3.1.2 json5==0.9.14 jsonpointer==2.4 -jsonschema==4.19.2 -jsonschema-specifications==2023.7.1 +jsonschema==4.20.0 +jsonschema-specifications==2023.11.2 jupyter==1.0.0 -jupyter-cache==0.6.1 +jupyter-cache==1.0.0 jupyter-client==8.6.0 jupyter-console==6.6.3 jupyter-core==5.5.0 jupyter-events==0.9.0 -jupyter-lsp==2.2.0 -jupyter-server==2.10.0 +jupyter-lsp==2.2.1 +jupyter-server==2.12.1 jupyter-server-terminals==0.4.4 -jupyterlab==4.0.8 +jupyterlab==4.0.9 jupyterlab-code-formatter==2.2.1 -jupyterlab-lsp==5.0.0 +jupyterlab-lsp==5.0.1 jupyterlab-myst==2.1.0 -jupyterlab-pygments==0.2.2 -jupyterlab-server==2.25.1 +jupyterlab-pygments==0.3.0 +jupyterlab-server==2.25.2 jupyterlab-widgets==3.0.9 kiwisolver==1.4.5 latexcodec==2.0.1 livereload==2.6.3 markdown-it-py==2.2.0 markupsafe==2.1.3 -matplotlib==3.8.1 +matplotlib==3.8.2 matplotlib-inline==0.1.6 mbstrdecoder==1.1.3 mdit-py-plugins==0.3.5 mdurl==0.1.2 mistune==3.0.2 mpmath==1.3.0 -mypy==1.6.1 +mypy==1.7.1 mypy-extensions==1.0.0 -myst-nb==0.17.2 -myst-parser==0.18.1 -nbclient==0.7.4 -nbconvert==7.11.0 +myst-nb==1.0.0 +myst-parser==1.0.0 +nbclient==0.9.0 +nbconvert==7.12.0 nbformat==5.9.2 nest-asyncio==1.5.8 nodeenv==1.8.0 @@ -110,24 +110,24 @@ pandocfilters==1.5.0 parso==0.8.3 pathspec==0.11.2 pathvalidate==3.2.0 -pexpect==4.8.0 +pexpect==4.9.0 pillow==10.1.0 -platformdirs==3.11.0 +platformdirs==4.1.0 pluggy==1.3.0 pre-commit==3.5.0 -prometheus-client==0.18.0 -prompt-toolkit==3.0.39 +prometheus-client==0.19.0 +prompt-toolkit==3.0.41 psutil==5.9.6 ptyprocess==0.7.0 pure-eval==0.2.2 pybtex==0.24.0 pybtex-docutils==1.0.3 pycparser==2.21 -pydantic==2.4.2 -pydantic-core==2.10.1 -pydata-sphinx-theme==0.14.3 +pydantic==2.5.2 +pydantic-core==2.14.5 +pydata-sphinx-theme==0.14.4 pygithub==2.1.1 -pygments==2.16.1 +pygments==2.17.2 pyjwt==2.8.0 pynacl==1.5.0 pyparsing==3.1.1 @@ -135,26 +135,26 @@ pyproject-api==1.6.1 pytablewriter==1.2.0 pytest==7.4.3 pytest-cov==4.1.0 -pytest-xdist==3.3.1 +pytest-xdist==3.5.0 python-dateutil==2.8.2 -python-gitlab==4.1.1 +python-gitlab==4.2.0 python-json-logger==2.0.7 python-lsp-jsonrpc==1.1.2 python-lsp-server==1.9.0 pytoolconfig==1.2.6 pytz==2023.3.post1 pyyaml==6.0.1 -pyzmq==25.1.1 -qtconsole==5.5.0 +pyzmq==25.1.2 +qtconsole==5.5.1 qtpy==2.4.1 -referencing==0.30.2 +referencing==0.32.0 requests==2.31.0 requests-toolbelt==1.0.0 rfc3339-validator==0.1.4 rfc3986-validator==0.1.1 rope==1.11.0 -rpds-py==0.12.0 -ruff==0.1.4 +rpds-py==0.13.2 +ruff==0.1.7 send2trash==1.8.2 six==1.16.0 sniffio==1.3.0 @@ -183,30 +183,30 @@ sympy==1.12 tabledata==1.3.3 tabulate==0.9.0 tcolorpy==0.1.4 -terminado==0.17.1 +terminado==0.18.0 tinycss2==1.2.1 tomli==2.0.1 -tornado==6.3.3 -tox==4.11.3 -traitlets==5.13.0 +tornado==6.4 +tox==4.11.4 +traitlets==5.14.0 typepy==1.3.2 types-docutils==0.20.0.3 types-pkg-resources==0.1.3 types-python-dateutil==2.8.19.14 types-pyyaml==6.0.12.12 -types-setuptools==68.2.0.0 +types-setuptools==69.0.0.0 typing-extensions==4.8.0 ujson==5.8.0 uri-template==1.3.0 -urllib3==2.0.7 -virtualenv==20.24.6 -wcwidth==0.2.9 +urllib3==2.1.0 +virtualenv==20.25.0 +wcwidth==0.2.12 webcolors==1.13 webencodings==0.5.1 -websocket-client==1.6.4 -wheel==0.41.3 +websocket-client==1.7.0 +wheel==0.42.0 widgetsnbextension==4.0.9 -wrapt==1.15.0 +wrapt==1.16.0 zipp==3.17.0 # The following packages are considered to be unsafe in a requirements file: diff --git a/.constraints/py3.11.txt b/.constraints/py3.11.txt index 4270f330..453b8f6a 100644 --- a/.constraints/py3.11.txt +++ b/.constraints/py3.11.txt @@ -7,7 +7,7 @@ accessible-pygments==0.0.4 alabaster==0.7.13 annotated-types==0.6.0 -anyio==4.0.0 +anyio==4.1.0 argon2-cffi==23.1.0 argon2-cffi-bindings==21.2.0 arrow==1.3.0 @@ -19,7 +19,7 @@ beautifulsoup4==4.12.2 black==23.11.0 bleach==6.1.0 cachetools==5.3.2 -certifi==2023.7.22 +certifi==2023.11.17 cffi==1.16.0 cfgv==3.4.0 chardet==5.2.0 @@ -29,7 +29,7 @@ colorama==0.4.6 comm==0.2.0 contourpy==1.2.0 coverage==7.3.2 -cryptography==41.0.5 +cryptography==41.0.7 cycler==0.12.1 dataproperty==1.0.1 debugpy==1.8.0 @@ -39,64 +39,64 @@ deprecated==1.2.14 distlib==0.3.7 docstring-to-markdown==0.13 docutils==0.17.1 -dominate==2.8.0 +dominate==2.9.0 execnet==2.0.2 executing==2.0.1 -fastjsonschema==2.18.1 +fastjsonschema==2.19.0 feynman==2.1.0 filelock==3.13.1 -fonttools==4.44.0 +fonttools==4.46.0 fqdn==1.5.1 -greenlet==3.0.1 -identify==2.5.31 -idna==3.4 +greenlet==3.0.2 +identify==2.5.33 +idna==3.6 imagesize==1.4.1 -importlib-metadata==6.8.0 +importlib-metadata==7.0.0 iniconfig==2.0.0 -ipykernel==6.26.0 -ipython==8.17.2 +ipykernel==6.27.1 +ipython==8.18.1 ipywidgets==8.1.1 isoduration==20.11.0 jedi==0.19.1 jinja2==3.1.2 json5==0.9.14 jsonpointer==2.4 -jsonschema==4.19.2 -jsonschema-specifications==2023.7.1 +jsonschema==4.20.0 +jsonschema-specifications==2023.11.2 jupyter==1.0.0 -jupyter-cache==0.6.1 +jupyter-cache==1.0.0 jupyter-client==8.6.0 jupyter-console==6.6.3 jupyter-core==5.5.0 jupyter-events==0.9.0 -jupyter-lsp==2.2.0 -jupyter-server==2.10.0 +jupyter-lsp==2.2.1 +jupyter-server==2.12.1 jupyter-server-terminals==0.4.4 -jupyterlab==4.0.8 +jupyterlab==4.0.9 jupyterlab-code-formatter==2.2.1 -jupyterlab-lsp==5.0.0 +jupyterlab-lsp==5.0.1 jupyterlab-myst==2.1.0 -jupyterlab-pygments==0.2.2 -jupyterlab-server==2.25.1 +jupyterlab-pygments==0.3.0 +jupyterlab-server==2.25.2 jupyterlab-widgets==3.0.9 kiwisolver==1.4.5 latexcodec==2.0.1 livereload==2.6.3 markdown-it-py==2.2.0 markupsafe==2.1.3 -matplotlib==3.8.1 +matplotlib==3.8.2 matplotlib-inline==0.1.6 mbstrdecoder==1.1.3 mdit-py-plugins==0.3.5 mdurl==0.1.2 mistune==3.0.2 mpmath==1.3.0 -mypy==1.6.1 +mypy==1.7.1 mypy-extensions==1.0.0 -myst-nb==0.17.2 -myst-parser==0.18.1 -nbclient==0.7.4 -nbconvert==7.11.0 +myst-nb==1.0.0 +myst-parser==1.0.0 +nbclient==0.9.0 +nbconvert==7.12.0 nbformat==5.9.2 nest-asyncio==1.5.8 nodeenv==1.8.0 @@ -109,24 +109,24 @@ pandocfilters==1.5.0 parso==0.8.3 pathspec==0.11.2 pathvalidate==3.2.0 -pexpect==4.8.0 +pexpect==4.9.0 pillow==10.1.0 -platformdirs==3.11.0 +platformdirs==4.1.0 pluggy==1.3.0 pre-commit==3.5.0 -prometheus-client==0.18.0 -prompt-toolkit==3.0.39 +prometheus-client==0.19.0 +prompt-toolkit==3.0.41 psutil==5.9.6 ptyprocess==0.7.0 pure-eval==0.2.2 pybtex==0.24.0 pybtex-docutils==1.0.3 pycparser==2.21 -pydantic==2.4.2 -pydantic-core==2.10.1 -pydata-sphinx-theme==0.14.3 +pydantic==2.5.2 +pydantic-core==2.14.5 +pydata-sphinx-theme==0.14.4 pygithub==2.1.1 -pygments==2.16.1 +pygments==2.17.2 pyjwt==2.8.0 pynacl==1.5.0 pyparsing==3.1.1 @@ -134,26 +134,26 @@ pyproject-api==1.6.1 pytablewriter==1.2.0 pytest==7.4.3 pytest-cov==4.1.0 -pytest-xdist==3.3.1 +pytest-xdist==3.5.0 python-dateutil==2.8.2 -python-gitlab==4.1.1 +python-gitlab==4.2.0 python-json-logger==2.0.7 python-lsp-jsonrpc==1.1.2 python-lsp-server==1.9.0 pytoolconfig==1.2.6 pytz==2023.3.post1 pyyaml==6.0.1 -pyzmq==25.1.1 -qtconsole==5.5.0 +pyzmq==25.1.2 +qtconsole==5.5.1 qtpy==2.4.1 -referencing==0.30.2 +referencing==0.32.0 requests==2.31.0 requests-toolbelt==1.0.0 rfc3339-validator==0.1.4 rfc3986-validator==0.1.1 rope==1.11.0 -rpds-py==0.12.0 -ruff==0.1.4 +rpds-py==0.13.2 +ruff==0.1.7 send2trash==1.8.2 six==1.16.0 sniffio==1.3.0 @@ -182,29 +182,29 @@ sympy==1.12 tabledata==1.3.3 tabulate==0.9.0 tcolorpy==0.1.4 -terminado==0.17.1 +terminado==0.18.0 tinycss2==1.2.1 -tornado==6.3.3 -tox==4.11.3 -traitlets==5.13.0 +tornado==6.4 +tox==4.11.4 +traitlets==5.14.0 typepy==1.3.2 types-docutils==0.20.0.3 types-pkg-resources==0.1.3 types-python-dateutil==2.8.19.14 types-pyyaml==6.0.12.12 -types-setuptools==68.2.0.0 +types-setuptools==69.0.0.0 typing-extensions==4.8.0 ujson==5.8.0 uri-template==1.3.0 -urllib3==2.0.7 -virtualenv==20.24.6 -wcwidth==0.2.9 +urllib3==2.1.0 +virtualenv==20.25.0 +wcwidth==0.2.12 webcolors==1.13 webencodings==0.5.1 -websocket-client==1.6.4 -wheel==0.41.3 +websocket-client==1.7.0 +wheel==0.42.0 widgetsnbextension==4.0.9 -wrapt==1.15.0 +wrapt==1.16.0 zipp==3.17.0 # The following packages are considered to be unsafe in a requirements file: diff --git a/.constraints/py3.7.txt b/.constraints/py3.7.txt index 3c474ba8..8a345de9 100644 --- a/.constraints/py3.7.txt +++ b/.constraints/py3.7.txt @@ -21,7 +21,7 @@ black==23.3.0 bleach==6.0.0 cached-property==1.5.2 cachetools==5.3.2 -certifi==2023.7.22 +certifi==2023.11.17 cffi==1.15.1 cfgv==3.3.1 chardet==5.2.0 @@ -30,7 +30,7 @@ click==8.1.7 colorama==0.4.6 comm==0.1.4 coverage==7.2.7 -cryptography==41.0.5 +cryptography==41.0.7 cycler==0.11.0 dataproperty==1.0.1 debugpy==1.7.0 @@ -40,18 +40,18 @@ deprecated==1.2.14 distlib==0.3.7 docstring-to-markdown==0.13 docutils==0.17.1 -dominate==2.8.0 +dominate==2.9.0 entrypoints==0.4 -exceptiongroup==1.1.3 +exceptiongroup==1.2.0 execnet==2.0.2 -fastjsonschema==2.18.1 +fastjsonschema==2.19.0 feynman==2.1.0 filelock==3.12.2 fonttools==4.38.0 fqdn==1.5.1 -greenlet==3.0.1 +greenlet==3.0.2 identify==2.5.24 -idna==3.4 +idna==3.6 imagesize==1.4.1 importlib-metadata==6.7.0 importlib-resources==5.12.0 @@ -114,25 +114,25 @@ pandocfilters==1.5.0 parso==0.8.3 pathspec==0.11.2 pathvalidate==3.2.0 -pexpect==4.8.0 +pexpect==4.9.0 pickleshare==0.7.5 pillow==9.5.0 pkgutil-resolve-name==1.3.10 -platformdirs==3.11.0 +platformdirs==4.0.0 pluggy==1.2.0 pre-commit==2.21.0 prometheus-client==0.17.1 -prompt-toolkit==3.0.39 +prompt-toolkit==3.0.41 psutil==5.9.6 ptyprocess==0.7.0 pybtex==0.24.0 pybtex-docutils==1.0.3 pycparser==2.21 -pydantic==2.4.2 -pydantic-core==2.10.1 +pydantic==2.5.2 +pydantic-core==2.14.5 pydata-sphinx-theme==0.13.3 pygithub==2.1.1 -pygments==2.16.1 +pygments==2.17.2 pyjwt==2.8.0 pynacl==1.5.0 pyparsing==3.1.1 @@ -141,7 +141,7 @@ pyrsistent==0.19.3 pytablewriter==1.2.0 pytest==7.4.3 pytest-cov==4.1.0 -pytest-xdist==3.3.1 +pytest-xdist==3.5.0 python-dateutil==2.8.2 python-gitlab==3.15.0 python-json-logger==2.0.7 @@ -158,7 +158,7 @@ requests-toolbelt==1.0.0 rfc3339-validator==0.1.4 rfc3986-validator==0.1.1 rope==1.9.0 -ruff==0.1.4 +ruff==0.1.7 send2trash==1.8.2 six==1.16.0 sniffio==1.3.0 @@ -198,19 +198,19 @@ types-docutils==0.20.0.3 types-pkg-resources==0.1.3 types-python-dateutil==2.8.19.14 types-pyyaml==6.0.12.12 -types-setuptools==68.2.0.0 +types-setuptools==69.0.0.0 typing-extensions==4.7.1 ujson==5.7.0 uri-template==1.3.0 urllib3==2.0.7 -virtualenv==20.24.6 -wcwidth==0.2.9 +virtualenv==20.25.0 +wcwidth==0.2.12 webcolors==1.13 webencodings==0.5.1 websocket-client==1.6.1 -wheel==0.41.3 +wheel==0.42.0 widgetsnbextension==4.0.9 -wrapt==1.15.0 +wrapt==1.16.0 y-py==0.5.9 ypy-websocket==0.8.2 zipp==3.15.0 diff --git a/.constraints/py3.8.txt b/.constraints/py3.8.txt index ee679aa1..f1c045b2 100644 --- a/.constraints/py3.8.txt +++ b/.constraints/py3.8.txt @@ -7,7 +7,7 @@ accessible-pygments==0.0.4 alabaster==0.7.13 annotated-types==0.6.0 -anyio==4.0.0 +anyio==4.1.0 argon2-cffi==23.1.0 argon2-cffi-bindings==21.2.0 arrow==1.3.0 @@ -20,7 +20,7 @@ beautifulsoup4==4.12.2 black==23.11.0 bleach==6.1.0 cachetools==5.3.2 -certifi==2023.7.22 +certifi==2023.11.17 cffi==1.16.0 cfgv==3.4.0 chardet==5.2.0 @@ -30,7 +30,7 @@ colorama==0.4.6 comm==0.2.0 contourpy==1.1.1 coverage==7.3.2 -cryptography==41.0.5 +cryptography==41.0.7 cycler==0.12.1 dataproperty==1.0.1 debugpy==1.8.0 @@ -40,23 +40,23 @@ deprecated==1.2.14 distlib==0.3.7 docstring-to-markdown==0.13 docutils==0.17.1 -dominate==2.8.0 -exceptiongroup==1.1.3 +dominate==2.9.0 +exceptiongroup==1.2.0 execnet==2.0.2 executing==2.0.1 -fastjsonschema==2.18.1 +fastjsonschema==2.19.0 feynman==2.1.0 filelock==3.13.1 -fonttools==4.44.0 +fonttools==4.46.0 fqdn==1.5.1 -greenlet==3.0.1 -identify==2.5.31 -idna==3.4 +greenlet==3.0.2 +identify==2.5.33 +idna==3.6 imagesize==1.4.1 -importlib-metadata==6.8.0 +importlib-metadata==7.0.0 importlib-resources==6.1.1 iniconfig==2.0.0 -ipykernel==6.26.0 +ipykernel==6.27.1 ipython==8.12.3 ipywidgets==8.1.1 isoduration==20.11.0 @@ -64,42 +64,42 @@ jedi==0.19.1 jinja2==3.1.2 json5==0.9.14 jsonpointer==2.4 -jsonschema==4.19.2 -jsonschema-specifications==2023.7.1 +jsonschema==4.20.0 +jsonschema-specifications==2023.11.2 jupyter==1.0.0 jupyter-cache==0.6.1 jupyter-client==8.6.0 jupyter-console==6.6.3 jupyter-core==5.5.0 jupyter-events==0.9.0 -jupyter-lsp==2.2.0 -jupyter-server==2.10.0 +jupyter-lsp==2.2.1 +jupyter-server==2.12.1 jupyter-server-terminals==0.4.4 -jupyterlab==4.0.8 +jupyterlab==4.0.9 jupyterlab-code-formatter==2.2.1 -jupyterlab-lsp==5.0.0 +jupyterlab-lsp==5.0.1 jupyterlab-myst==2.1.0 -jupyterlab-pygments==0.2.2 -jupyterlab-server==2.25.1 +jupyterlab-pygments==0.3.0 +jupyterlab-server==2.25.2 jupyterlab-widgets==3.0.9 kiwisolver==1.4.5 latexcodec==2.0.1 livereload==2.6.3 markdown-it-py==2.2.0 markupsafe==2.1.3 -matplotlib==3.7.3 +matplotlib==3.7.4 matplotlib-inline==0.1.6 mbstrdecoder==1.1.3 mdit-py-plugins==0.3.5 mdurl==0.1.2 mistune==3.0.2 mpmath==1.3.0 -mypy==1.6.1 +mypy==1.7.1 mypy-extensions==1.0.0 myst-nb==0.17.2 myst-parser==0.18.1 nbclient==0.7.4 -nbconvert==7.11.0 +nbconvert==7.12.0 nbformat==5.9.2 nest-asyncio==1.5.8 nodeenv==1.8.0 @@ -112,26 +112,26 @@ pandocfilters==1.5.0 parso==0.8.3 pathspec==0.11.2 pathvalidate==3.2.0 -pexpect==4.8.0 +pexpect==4.9.0 pickleshare==0.7.5 pillow==10.1.0 pkgutil-resolve-name==1.3.10 -platformdirs==3.11.0 +platformdirs==4.1.0 pluggy==1.3.0 pre-commit==3.5.0 -prometheus-client==0.18.0 -prompt-toolkit==3.0.39 +prometheus-client==0.19.0 +prompt-toolkit==3.0.41 psutil==5.9.6 ptyprocess==0.7.0 pure-eval==0.2.2 pybtex==0.24.0 pybtex-docutils==1.0.3 pycparser==2.21 -pydantic==2.4.2 -pydantic-core==2.10.1 -pydata-sphinx-theme==0.14.3 +pydantic==2.5.2 +pydantic-core==2.14.5 +pydata-sphinx-theme==0.14.4 pygithub==2.1.1 -pygments==2.16.1 +pygments==2.17.2 pyjwt==2.8.0 pynacl==1.5.0 pyparsing==3.1.1 @@ -139,26 +139,26 @@ pyproject-api==1.6.1 pytablewriter==1.2.0 pytest==7.4.3 pytest-cov==4.1.0 -pytest-xdist==3.3.1 +pytest-xdist==3.5.0 python-dateutil==2.8.2 -python-gitlab==4.1.1 +python-gitlab==4.2.0 python-json-logger==2.0.7 python-lsp-jsonrpc==1.1.2 python-lsp-server==1.9.0 pytoolconfig==1.2.6 pytz==2023.3.post1 pyyaml==6.0.1 -pyzmq==25.1.1 -qtconsole==5.5.0 +pyzmq==25.1.2 +qtconsole==5.5.1 qtpy==2.4.1 -referencing==0.30.2 +referencing==0.32.0 requests==2.31.0 requests-toolbelt==1.0.0 rfc3339-validator==0.1.4 rfc3986-validator==0.1.1 rope==1.11.0 -rpds-py==0.12.0 -ruff==0.1.4 +rpds-py==0.13.2 +ruff==0.1.7 send2trash==1.8.2 six==1.16.0 sniffio==1.3.0 @@ -187,30 +187,30 @@ sympy==1.12 tabledata==1.3.3 tabulate==0.9.0 tcolorpy==0.1.4 -terminado==0.17.1 +terminado==0.18.0 tinycss2==1.2.1 tomli==2.0.1 -tornado==6.3.3 -tox==4.11.3 -traitlets==5.13.0 +tornado==6.4 +tox==4.11.4 +traitlets==5.14.0 typepy==1.3.2 types-docutils==0.20.0.3 types-pkg-resources==0.1.3 types-python-dateutil==2.8.19.14 types-pyyaml==6.0.12.12 -types-setuptools==68.2.0.0 +types-setuptools==69.0.0.0 typing-extensions==4.8.0 ujson==5.8.0 uri-template==1.3.0 -urllib3==2.0.7 -virtualenv==20.24.6 -wcwidth==0.2.9 +urllib3==2.1.0 +virtualenv==20.25.0 +wcwidth==0.2.12 webcolors==1.13 webencodings==0.5.1 -websocket-client==1.6.4 -wheel==0.41.3 +websocket-client==1.7.0 +wheel==0.42.0 widgetsnbextension==4.0.9 -wrapt==1.15.0 +wrapt==1.16.0 zipp==3.17.0 # The following packages are considered to be unsafe in a requirements file: diff --git a/.constraints/py3.9.txt b/.constraints/py3.9.txt index 5cbd8132..1ec1fa8a 100644 --- a/.constraints/py3.9.txt +++ b/.constraints/py3.9.txt @@ -7,7 +7,7 @@ accessible-pygments==0.0.4 alabaster==0.7.13 annotated-types==0.6.0 -anyio==4.0.0 +anyio==4.1.0 argon2-cffi==23.1.0 argon2-cffi-bindings==21.2.0 arrow==1.3.0 @@ -19,7 +19,7 @@ beautifulsoup4==4.12.2 black==23.11.0 bleach==6.1.0 cachetools==5.3.2 -certifi==2023.7.22 +certifi==2023.11.17 cffi==1.16.0 cfgv==3.4.0 chardet==5.2.0 @@ -29,7 +29,7 @@ colorama==0.4.6 comm==0.2.0 contourpy==1.2.0 coverage==7.3.2 -cryptography==41.0.5 +cryptography==41.0.7 cycler==0.12.1 dataproperty==1.0.1 debugpy==1.8.0 @@ -39,66 +39,66 @@ deprecated==1.2.14 distlib==0.3.7 docstring-to-markdown==0.13 docutils==0.17.1 -dominate==2.8.0 -exceptiongroup==1.1.3 +dominate==2.9.0 +exceptiongroup==1.2.0 execnet==2.0.2 executing==2.0.1 -fastjsonschema==2.18.1 +fastjsonschema==2.19.0 feynman==2.1.0 filelock==3.13.1 -fonttools==4.44.0 +fonttools==4.46.0 fqdn==1.5.1 -greenlet==3.0.1 -identify==2.5.31 -idna==3.4 +greenlet==3.0.2 +identify==2.5.33 +idna==3.6 imagesize==1.4.1 -importlib-metadata==6.8.0 +importlib-metadata==7.0.0 importlib-resources==6.1.1 iniconfig==2.0.0 -ipykernel==6.26.0 -ipython==8.17.2 +ipykernel==6.27.1 +ipython==8.18.1 ipywidgets==8.1.1 isoduration==20.11.0 jedi==0.19.1 jinja2==3.1.2 json5==0.9.14 jsonpointer==2.4 -jsonschema==4.19.2 -jsonschema-specifications==2023.7.1 +jsonschema==4.20.0 +jsonschema-specifications==2023.11.2 jupyter==1.0.0 -jupyter-cache==0.6.1 +jupyter-cache==1.0.0 jupyter-client==8.6.0 jupyter-console==6.6.3 jupyter-core==5.5.0 jupyter-events==0.9.0 -jupyter-lsp==2.2.0 -jupyter-server==2.10.0 +jupyter-lsp==2.2.1 +jupyter-server==2.12.1 jupyter-server-terminals==0.4.4 -jupyterlab==4.0.8 +jupyterlab==4.0.9 jupyterlab-code-formatter==2.2.1 -jupyterlab-lsp==5.0.0 +jupyterlab-lsp==5.0.1 jupyterlab-myst==2.1.0 -jupyterlab-pygments==0.2.2 -jupyterlab-server==2.25.1 +jupyterlab-pygments==0.3.0 +jupyterlab-server==2.25.2 jupyterlab-widgets==3.0.9 kiwisolver==1.4.5 latexcodec==2.0.1 livereload==2.6.3 markdown-it-py==2.2.0 markupsafe==2.1.3 -matplotlib==3.8.1 +matplotlib==3.8.2 matplotlib-inline==0.1.6 mbstrdecoder==1.1.3 mdit-py-plugins==0.3.5 mdurl==0.1.2 mistune==3.0.2 mpmath==1.3.0 -mypy==1.6.1 +mypy==1.7.1 mypy-extensions==1.0.0 -myst-nb==0.17.2 -myst-parser==0.18.1 -nbclient==0.7.4 -nbconvert==7.11.0 +myst-nb==1.0.0 +myst-parser==1.0.0 +nbclient==0.9.0 +nbconvert==7.12.0 nbformat==5.9.2 nest-asyncio==1.5.8 nodeenv==1.8.0 @@ -111,24 +111,24 @@ pandocfilters==1.5.0 parso==0.8.3 pathspec==0.11.2 pathvalidate==3.2.0 -pexpect==4.8.0 +pexpect==4.9.0 pillow==10.1.0 -platformdirs==3.11.0 +platformdirs==4.1.0 pluggy==1.3.0 pre-commit==3.5.0 -prometheus-client==0.18.0 -prompt-toolkit==3.0.39 +prometheus-client==0.19.0 +prompt-toolkit==3.0.41 psutil==5.9.6 ptyprocess==0.7.0 pure-eval==0.2.2 pybtex==0.24.0 pybtex-docutils==1.0.3 pycparser==2.21 -pydantic==2.4.2 -pydantic-core==2.10.1 -pydata-sphinx-theme==0.14.3 +pydantic==2.5.2 +pydantic-core==2.14.5 +pydata-sphinx-theme==0.14.4 pygithub==2.1.1 -pygments==2.16.1 +pygments==2.17.2 pyjwt==2.8.0 pynacl==1.5.0 pyparsing==3.1.1 @@ -136,26 +136,26 @@ pyproject-api==1.6.1 pytablewriter==1.2.0 pytest==7.4.3 pytest-cov==4.1.0 -pytest-xdist==3.3.1 +pytest-xdist==3.5.0 python-dateutil==2.8.2 -python-gitlab==4.1.1 +python-gitlab==4.2.0 python-json-logger==2.0.7 python-lsp-jsonrpc==1.1.2 python-lsp-server==1.9.0 pytoolconfig==1.2.6 pytz==2023.3.post1 pyyaml==6.0.1 -pyzmq==25.1.1 -qtconsole==5.5.0 +pyzmq==25.1.2 +qtconsole==5.5.1 qtpy==2.4.1 -referencing==0.30.2 +referencing==0.32.0 requests==2.31.0 requests-toolbelt==1.0.0 rfc3339-validator==0.1.4 rfc3986-validator==0.1.1 rope==1.11.0 -rpds-py==0.12.0 -ruff==0.1.4 +rpds-py==0.13.2 +ruff==0.1.7 send2trash==1.8.2 six==1.16.0 sniffio==1.3.0 @@ -184,30 +184,30 @@ sympy==1.12 tabledata==1.3.3 tabulate==0.9.0 tcolorpy==0.1.4 -terminado==0.17.1 +terminado==0.18.0 tinycss2==1.2.1 tomli==2.0.1 -tornado==6.3.3 -tox==4.11.3 -traitlets==5.13.0 +tornado==6.4 +tox==4.11.4 +traitlets==5.14.0 typepy==1.3.2 types-docutils==0.20.0.3 types-pkg-resources==0.1.3 types-python-dateutil==2.8.19.14 types-pyyaml==6.0.12.12 -types-setuptools==68.2.0.0 +types-setuptools==69.0.0.0 typing-extensions==4.8.0 ujson==5.8.0 uri-template==1.3.0 -urllib3==2.0.7 -virtualenv==20.24.6 -wcwidth==0.2.9 +urllib3==2.1.0 +virtualenv==20.25.0 +wcwidth==0.2.12 webcolors==1.13 webencodings==0.5.1 -websocket-client==1.6.4 -wheel==0.41.3 +websocket-client==1.7.0 +wheel==0.42.0 widgetsnbextension==4.0.9 -wrapt==1.15.0 +wrapt==1.16.0 zipp==3.17.0 # The following packages are considered to be unsafe in a requirements file: diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index e558e114..d057c540 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.1 + rev: 0.1.9 hooks: - id: check-dev-files args: @@ -52,7 +52,7 @@ repos: - id: colab-toc-visible - id: fix-nbformat-version - repo: https://github.com/nbQA-dev/nbQA - rev: 1.7.0 + rev: 1.7.1 hooks: - id: nbqa-pyupgrade args: @@ -75,7 +75,7 @@ repos: - id: blacken-docs - repo: https://github.com/sirosen/check-jsonschema - rev: 0.27.1 + rev: 0.27.3 hooks: - id: check-jsonschema name: Check project inventory YAML files @@ -85,7 +85,7 @@ repos: args: ["--schemafile", "./docs/software/project-inventory-schema.json"] - repo: https://github.com/streetsidesoftware/cspell-cli - rev: v8.0.0 + rev: v8.1.1 hooks: - id: cspell @@ -136,12 +136,12 @@ repos: metadata.vscode - repo: https://github.com/pre-commit/mirrors-prettier - rev: v3.0.3 + rev: v4.0.0-alpha.3-1 hooks: - id: prettier - repo: https://github.com/ComPWA/mirrors-pyright - rev: v1.1.334 + rev: v1.1.339 hooks: - id: pyright @@ -153,7 +153,7 @@ repos: - --py37-plus - repo: https://github.com/astral-sh/ruff-pre-commit - rev: v0.1.4 + rev: v0.1.7 hooks: - id: ruff args: From 38e8f0d9698abf2abc7d6e529ede8152b8572cc0 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Sat, 9 Dec 2023 12:06:43 +0000 Subject: [PATCH 02/20] [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --- .cspell.json | 7 +++++- .gitpod.yml | 1 + .pre-commit-config.yaml | 48 ++++++++++++++--------------------------- .readthedocs.yml | 2 +- .vscode/settings.json | 3 ++- environment.yml | 6 +++--- pyproject.toml | 35 ++++++++++++++++++------------ 7 files changed, 50 insertions(+), 52 deletions(-) diff --git a/.cspell.json b/.cspell.json index e612b4c2..556275df 100644 --- a/.cspell.json +++ b/.cspell.json @@ -1,6 +1,11 @@ { "version": "0.2", - "enableFiletypes": ["git-commit", "julia", "jupyter"], + "enableFiletypes": [ + "git-commit", + "github-actions-workflow", + "julia", + "jupyter" + ], "flagWords": [ "analyse", "colour", diff --git a/.gitpod.yml b/.gitpod.yml index d981b21f..7945c72f 100644 --- a/.gitpod.yml +++ b/.gitpod.yml @@ -1,4 +1,5 @@ tasks: + - init: pyenv local 3.8 - init: pip install -c .constraints/py3.8.txt -e .[dev] github: diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index d057c540..bd2bb05f 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -4,6 +4,7 @@ ci: skip: - check-jsonschema - mypy + - prettier - pyright - taplo - update-json-schema @@ -14,6 +15,19 @@ repos: - id: check-hooks-apply - id: check-useless-excludes + - repo: https://github.com/ComPWA/repo-maintenance + rev: 0.1.9 + hooks: + - id: check-dev-files + args: + - --ci-skipped-tests=all + - --no-macos + - --no-prettierrc + - --pin-requirements=bimonthly + - --repo-name=PWA-pages + - --repo-title=PWA Pages + - id: colab-toc-visible + - id: fix-nbformat-version - repo: https://github.com/pre-commit/pre-commit-hooks rev: v4.5.0 hooks: @@ -38,29 +52,6 @@ repos: args: ["--django"] - id: trailing-whitespace - - repo: https://github.com/ComPWA/repo-maintenance - rev: 0.1.9 - hooks: - - id: check-dev-files - args: - - --ci-skipped-tests=all - - --no-macos - - --no-prettierrc - - --pin-requirements=bimonthly - - --repo-name=PWA-pages - - --repo-title=PWA Pages - - id: colab-toc-visible - - id: fix-nbformat-version - - 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: @@ -145,19 +136,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.7 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/.readthedocs.yml b/.readthedocs.yml index 855501d1..f34ae963 100644 --- a/.readthedocs.yml +++ b/.readthedocs.yml @@ -16,4 +16,4 @@ build: - graphviz jobs: post_install: - - pip install -e .[doc] -c .constraints/py3.8.txt + - pip install -c .constraints/py3.8.txt -e .[doc] diff --git a/.vscode/settings.json b/.vscode/settings.json index 267082a1..674fa963 100644 --- a/.vscode/settings.json +++ b/.vscode/settings.json @@ -17,7 +17,7 @@ }, "[python]": { "editor.codeActionsOnSave": { - "source.organizeImports": true + "source.organizeImports": "explicit" }, "editor.defaultFormatter": "ms-python.black-formatter", "editor.rulers": [88] @@ -31,6 +31,7 @@ "coverage-gutters.showGutterCoverage": false, "coverage-gutters.showLineCoverage": true, "cSpell.enabled": true, + "diffEditor.experimental.showMoves": true, "editor.formatOnSave": true, "files.watcherExclude": { "**/*_cache/**": true, diff --git a/environment.yml b/environment.yml index 027fe19c..281625db 100644 --- a/environment.yml +++ b/environment.yml @@ -6,6 +6,6 @@ dependencies: - pip - graphviz # for binder - pip: - - | - -c .constraints/py3.8.txt - -e .[dev] + - -c .constraints/py3.8.txt -e .[dev] +variables: + PRETTIER_LEGACY_CLI: "1" diff --git a/pyproject.toml b/pyproject.toml index 76347e38..86ef4ee1 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -85,10 +85,13 @@ format = [ ] jupyter = [ "PWA-pages[doc]", + "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"', ] @@ -195,20 +198,6 @@ module = ["sphinx.*"] ignore_missing_imports = true module = ["sphinxcontrib.bibtex.*"] -[tool.nbqa.addopts] -ruff = [ - "--extend-ignore=B018", - "--extend-ignore=C90", - "--extend-ignore=D", - "--extend-ignore=N806", - "--extend-ignore=N816", - "--extend-ignore=PLR09", - "--extend-ignore=PLR2004", - "--extend-ignore=PLW0602", - "--extend-ignore=PLW0603", - "--line-length=85", -] - [tool.pyright] exclude = [ "**/.git", @@ -265,6 +254,7 @@ testpaths = [ ] [tool.ruff] +extend-include = ["*.ipynb"] extend-select = [ "A", "B", @@ -319,6 +309,22 @@ target-version = "py37" task-tags = ["cspell"] [tool.ruff.per-file-ignores] +"*.ipynb" = [ + "B018", + "C90", + "D", + "E402", + "E703", + "N806", + "N816", + "PLR09", + "PLR2004", + "PLW0602", + "PLW0603", + "S101", + "T20", + "TCH00", +] "docs/*" = [ "E402", "INP001", @@ -339,6 +345,7 @@ task-tags = ["cspell"] "PLR0913", "PLR2004", "S101", + "T20", ] [tool.ruff.pydocstyle] From 1ed98e6252d06f8b34115a15a794dbda15ef9785 Mon Sep 17 00:00:00 2001 From: GitHub Date: Sat, 9 Dec 2023 12:08:39 +0000 Subject: [PATCH 03/20] MAINT: update pip constraints and pre-commit --- .constraints/py3.10.txt | 10 ++++++++++ .constraints/py3.11.txt | 10 ++++++++++ .constraints/py3.7.txt | 10 ++++++++++ .constraints/py3.8.txt | 10 ++++++++++ .constraints/py3.9.txt | 10 ++++++++++ 5 files changed, 50 insertions(+) diff --git a/.constraints/py3.10.txt b/.constraints/py3.10.txt index 4107d846..acee7223 100644 --- a/.constraints/py3.10.txt +++ b/.constraints/py3.10.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 @@ -48,6 +49,8 @@ feynman==2.1.0 filelock==3.13.1 fonttools==4.46.0 fqdn==1.5.1 +gitdb==4.0.11 +gitpython==3.1.40 greenlet==3.0.2 identify==2.5.33 idna==3.6 @@ -58,6 +61,7 @@ ipykernel==6.27.1 ipython==8.18.1 ipywidgets==8.1.1 isoduration==20.11.0 +isort==5.12.0 jedi==0.19.1 jinja2==3.1.2 json5==0.9.14 @@ -72,9 +76,11 @@ jupyter-core==5.5.0 jupyter-events==0.9.0 jupyter-lsp==2.2.1 jupyter-server==2.12.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 @@ -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.8.2 @@ -98,6 +105,7 @@ myst-nb==1.0.0 myst-parser==1.0.0 nbclient==0.9.0 nbconvert==7.12.0 +nbdime==4.0.1 nbformat==5.9.2 nest-asyncio==1.5.8 nodeenv==1.8.0 @@ -140,6 +148,7 @@ python-dateutil==2.8.2 python-gitlab==4.2.0 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 @@ -157,6 +166,7 @@ rpds-py==0.13.2 ruff==0.1.7 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 453b8f6a..ed50055a 100644 --- a/.constraints/py3.11.txt +++ b/.constraints/py3.11.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 @@ -47,6 +48,8 @@ feynman==2.1.0 filelock==3.13.1 fonttools==4.46.0 fqdn==1.5.1 +gitdb==4.0.11 +gitpython==3.1.40 greenlet==3.0.2 identify==2.5.33 idna==3.6 @@ -57,6 +60,7 @@ ipykernel==6.27.1 ipython==8.18.1 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.12.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.8.2 @@ -97,6 +104,7 @@ myst-nb==1.0.0 myst-parser==1.0.0 nbclient==0.9.0 nbconvert==7.12.0 +nbdime==4.0.1 nbformat==5.9.2 nest-asyncio==1.5.8 nodeenv==1.8.0 @@ -139,6 +147,7 @@ python-dateutil==2.8.2 python-gitlab==4.2.0 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 @@ -156,6 +165,7 @@ rpds-py==0.13.2 ruff==0.1.7 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 8a345de9..bb05c686 100644 --- a/.constraints/py3.7.txt +++ b/.constraints/py3.7.txt @@ -21,6 +21,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 @@ -49,6 +50,8 @@ feynman==2.1.0 filelock==3.12.2 fonttools==4.38.0 fqdn==1.5.1 +gitdb==4.0.11 +gitpython==3.1.40 greenlet==3.0.2 identify==2.5.24 idna==3.6 @@ -61,6 +64,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 @@ -75,10 +79,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 @@ -87,6 +93,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 @@ -103,6 +110,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 nest-asyncio==1.5.8 nodeenv==1.8.0 @@ -146,6 +154,7 @@ python-dateutil==2.8.2 python-gitlab==3.15.0 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 @@ -161,6 +170,7 @@ rope==1.9.0 ruff==0.1.7 send2trash==1.8.2 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 f1c045b2..71133ca6 100644 --- a/.constraints/py3.8.txt +++ b/.constraints/py3.8.txt @@ -20,6 +20,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 @@ -49,6 +50,8 @@ feynman==2.1.0 filelock==3.13.1 fonttools==4.46.0 fqdn==1.5.1 +gitdb==4.0.11 +gitpython==3.1.40 greenlet==3.0.2 identify==2.5.33 idna==3.6 @@ -60,6 +63,7 @@ ipykernel==6.27.1 ipython==8.12.3 ipywidgets==8.1.1 isoduration==20.11.0 +isort==5.12.0 jedi==0.19.1 jinja2==3.1.2 json5==0.9.14 @@ -74,9 +78,11 @@ jupyter-core==5.5.0 jupyter-events==0.9.0 jupyter-lsp==2.2.1 jupyter-server==2.12.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 @@ -85,6 +91,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 @@ -100,6 +107,7 @@ myst-nb==0.17.2 myst-parser==0.18.1 nbclient==0.7.4 nbconvert==7.12.0 +nbdime==4.0.1 nbformat==5.9.2 nest-asyncio==1.5.8 nodeenv==1.8.0 @@ -144,6 +152,7 @@ python-dateutil==2.8.2 python-gitlab==4.2.0 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 @@ -161,6 +170,7 @@ rpds-py==0.13.2 ruff==0.1.7 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 1ec1fa8a..4f410159 100644 --- a/.constraints/py3.9.txt +++ b/.constraints/py3.9.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 @@ -48,6 +49,8 @@ feynman==2.1.0 filelock==3.13.1 fonttools==4.46.0 fqdn==1.5.1 +gitdb==4.0.11 +gitpython==3.1.40 greenlet==3.0.2 identify==2.5.33 idna==3.6 @@ -59,6 +62,7 @@ ipykernel==6.27.1 ipython==8.18.1 ipywidgets==8.1.1 isoduration==20.11.0 +isort==5.12.0 jedi==0.19.1 jinja2==3.1.2 json5==0.9.14 @@ -73,9 +77,11 @@ jupyter-core==5.5.0 jupyter-events==0.9.0 jupyter-lsp==2.2.1 jupyter-server==2.12.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 @@ -84,6 +90,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 @@ -99,6 +106,7 @@ myst-nb==1.0.0 myst-parser==1.0.0 nbclient==0.9.0 nbconvert==7.12.0 +nbdime==4.0.1 nbformat==5.9.2 nest-asyncio==1.5.8 nodeenv==1.8.0 @@ -141,6 +149,7 @@ python-dateutil==2.8.2 python-gitlab==4.2.0 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 @@ -158,6 +167,7 @@ rpds-py==0.13.2 ruff==0.1.7 send2trash==1.8.2 six==1.16.0 +smmap==5.0.1 sniffio==1.3.0 snowballstemmer==2.2.0 soupsieve==2.5 From f61a2f56709d093de39137adfb3e85ec9759066b Mon Sep 17 00:00:00 2001 From: Remco de Boer <29308176+redeboer@users.noreply.github.com> Date: Sat, 9 Dec 2023 16:35:01 +0100 Subject: [PATCH 04/20] DX: define `docnblive` job in `tox.ini` --- tox.ini | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) diff --git a/tox.ini b/tox.ini index ca7bea7e..e664d22f 100644 --- a/tox.ini +++ b/tox.ini @@ -88,6 +88,35 @@ setenv = EXECUTE_NB = yes FORCE_COLOR = yes +[testenv:docnblive] +allowlist_externals = + sphinx-autobuild +commands = + sphinx-autobuild \ + --open-browser \ + --re-ignore .*/.ipynb_checkpoints/.* \ + --re-ignore .*/__pycache__/.* \ + --re-ignore .*\.gitignore \ + --re-ignore docs/.*\.csv \ + --re-ignore docs/.*\.gif \ + --re-ignore docs/.*\.gv \ + --re-ignore docs/.*\.inv \ + --re-ignore docs/.*\.json \ + --re-ignore docs/.*\.pickle \ + --re-ignore docs/.*\.png \ + --re-ignore docs/.*\.svg \ + --re-ignore docs/.*\.yaml \ + --re-ignore docs/.*\.yml \ + --re-ignore docs/_build/.* \ + --watch docs \ + docs/ docs/_build/html +description = + Set up a server to directly preview changes to the HTML pages +passenv = * +setenv = + EXECUTE_NB = yes + FORCE_COLOR = yes + [testenv:jcache] allowlist_externals = jcache From 7a3ea26e4d864ba1c37da484acd042c71e3f2650 Mon Sep 17 00:00:00 2001 From: Remco de Boer <29308176+redeboer@users.noreply.github.com> Date: Sat, 9 Dec 2023 16:37:23 +0100 Subject: [PATCH 05/20] MAINT: add back newline in pre-commit config --- .pre-commit-config.yaml | 1 + 1 file changed, 1 insertion(+) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index bd2bb05f..4e86878f 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -28,6 +28,7 @@ repos: - --repo-title=PWA Pages - id: colab-toc-visible - id: fix-nbformat-version + - repo: https://github.com/pre-commit/pre-commit-hooks rev: v4.5.0 hooks: From 5087668cb9bd99d8646b6d73c28cdb3f36a14948 Mon Sep 17 00:00:00 2001 From: Remco de Boer <29308176+redeboer@users.noreply.github.com> Date: Sat, 9 Dec 2023 16:41:28 +0100 Subject: [PATCH 06/20] DX: activate VSCode multi-file diff editor https://code.visualstudio.com/updates/v1_85\#_multifile-diff-editor --- .vscode/settings.json | 1 + 1 file changed, 1 insertion(+) diff --git a/.vscode/settings.json b/.vscode/settings.json index 674fa963..a0877d09 100644 --- a/.vscode/settings.json +++ b/.vscode/settings.json @@ -42,6 +42,7 @@ "git.rebaseWhenSync": true, "github-actions.workflows.pinned.workflows": [".github/workflows/ci.yml"], "livePreview.defaultPreviewPath": "docs/_build/html", + "multiDiffEditor.experimental.enabled": true, "mypy-type-checker.args": ["--config-file=${workspaceFolder}/pyproject.toml"], "mypy-type-checker.importStrategy": "fromEnvironment", "myst.preview.extensions": [ From ee200c59208b6f450033f8639b8bce1684269162 Mon Sep 17 00:00:00 2001 From: Remco de Boer <29308176+redeboer@users.noreply.github.com> Date: Sat, 9 Dec 2023 16:41:46 +0100 Subject: [PATCH 07/20] DX: define `nb` job in `tox.ini` --- pyproject.toml | 1 + tox.ini | 11 +++++++++++ 2 files changed, 12 insertions(+) diff --git a/pyproject.toml b/pyproject.toml index 86ef4ee1..3550222e 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -114,6 +114,7 @@ sty = [ "pre-commit >=1.4.0", ] test = [ + "nbmake", "pytest", "pytest-cov", "pytest-xdist", diff --git a/tox.ini b/tox.ini index e664d22f..8b7df1df 100644 --- a/tox.ini +++ b/tox.ini @@ -140,6 +140,17 @@ passenv = * setenv = FORCE_COLOR = yes +[testenv:nb] +allowlist_externals = + pytest +commands = + pytest --nbmake {posargs:docs} +description = + Run all notebooks with pytest +passenv = * +setenv = + PYTHONHASHSEED = 0 + [testenv:sty] allowlist_externals = mypy From 5a674c37cc260b088295c3a8f10783e90333c0f2 Mon Sep 17 00:00:00 2001 From: Remco de Boer <29308176+redeboer@users.noreply.github.com> Date: Sat, 9 Dec 2023 17:13:30 +0100 Subject: [PATCH 08/20] DOC: add back comma to reference style https://sphinxcontrib-bibtex.readthedocs.io/en/latest/usage.html\#referencing-style --- docs/conf.py | 22 ++-------------------- 1 file changed, 2 insertions(+), 20 deletions(-) diff --git a/docs/conf.py b/docs/conf.py index 1ed486fa..50f80f2d 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -8,7 +8,6 @@ # pyright: reportMissingImports=false from __future__ import annotations -import dataclasses import os import re import sys @@ -16,10 +15,9 @@ from functools import lru_cache from typing import TYPE_CHECKING, Any -import sphinxcontrib.bibtex.plugin # type: ignore[import] from docutils import nodes from pybtex.plugin import register_plugin -from pybtex.richtext import BaseText, Tag, Text +from pybtex.richtext import Tag, Text from pybtex.style.formatting.unsrt import Style as UnsrtStyle from pybtex.style.template import ( FieldIsMissing, @@ -32,7 +30,6 @@ sentence, words, ) -from sphinxcontrib.bibtex.style.referencing.author_year import AuthorYearReferenceStyle if TYPE_CHECKING: from docutils.nodes import Node as docutils_Node @@ -246,7 +243,7 @@ def get_minor_version(package_name: str) -> str: bibtex_bibfiles = [ "bibliography.bib", ] -bibtex_reference_style = "author_year_no_comma" +bibtex_reference_style = "author_year" # Settings for copybutton copybutton_prompt_is_regexp = True @@ -351,21 +348,6 @@ def role( # noqa: PLR0913 return role -# Specify bibliography style -@dataclasses.dataclass -class NoCommaReferenceStyle( - AuthorYearReferenceStyle # pyright: ignore[reportUntypedBaseClass] -): - author_year_sep: BaseText | str = " " - - -sphinxcontrib.bibtex.plugin.register_plugin( - "sphinxcontrib.bibtex.style.referencing", - "author_year_no_comma", - NoCommaReferenceStyle, -) - - @node def et_al(children, data, sep="", sep2=None, last_sep=None): # type: ignore[no-untyped-def] if sep2 is None: From 2633a1568daa4985cdd1c677d0398559889cc2fa Mon Sep 17 00:00:00 2001 From: Remco de Boer <29308176+redeboer@users.noreply.github.com> Date: Sat, 9 Dec 2023 17:17:20 +0100 Subject: [PATCH 09/20] DX: outsource bibliography style to `sphinx-pybtex-etal-style` --- docs/conf.py | 103 +------------------------------------------------ pyproject.toml | 1 + 2 files changed, 2 insertions(+), 102 deletions(-) diff --git a/docs/conf.py b/docs/conf.py index 50f80f2d..c15ef62c 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -16,26 +16,11 @@ from typing import TYPE_CHECKING, Any from docutils import nodes -from pybtex.plugin import register_plugin -from pybtex.richtext import Tag, Text -from pybtex.style.formatting.unsrt import Style as UnsrtStyle -from pybtex.style.template import ( - FieldIsMissing, - Node, - _format_list, - field, - href, - join, - node, - sentence, - words, -) if TYPE_CHECKING: from docutils.nodes import Node as docutils_Node from docutils.nodes import system_message from docutils.parsers.rst.states import Inliner - from pybtex.database import Entry from sphinx.application import Sphinx from sphinx.util.typing import RoleFunction @@ -113,6 +98,7 @@ def get_repository_name() -> str: "sphinx_copybutton", "sphinx_design", "sphinx_hep_pdgref", + "sphinx_pybtex_etal_style", "sphinx_thebe", "sphinx_togglebutton", "sphinxcontrib.bibtex", @@ -346,90 +332,3 @@ def role( # noqa: PLR0913 return [reference_node], [] return role - - -@node -def et_al(children, data, sep="", sep2=None, last_sep=None): # type: ignore[no-untyped-def] - if sep2 is None: - sep2 = sep - if last_sep is None: - last_sep = sep - parts = [part for part in _format_list(children, data) if part] - if len(parts) <= 1: - return Text(*parts) - if len(parts) == 2: # noqa: PLR2004 - return Text(sep2).join(parts) - if len(parts) == 3: # noqa: PLR2004 - return Text(last_sep).join([Text(sep).join(parts[:-1]), parts[-1]]) - return Text(parts[0], Tag("em", " et al")) - - -@node -def names(children, context, role, **kwargs): # type: ignore[no-untyped-def] - """Return formatted names.""" - assert not children - try: - persons = context["entry"].persons[role] - except KeyError: - raise FieldIsMissing(role, context["entry"]) from None - - style = context["style"] - formatted_names = [ - style.format_name(person, style.abbreviate_names) for person in persons - ] - return et_al(**kwargs)[formatted_names].format_data(context) - - -class MyStyle(UnsrtStyle): # pyright: ignore[reportUntypedBaseClass] - def __init__(self) -> None: - super().__init__(abbreviate_names=True) - - def format_names(self, role, as_sentence: bool = True) -> Node: # type: ignore[no-untyped-def] - formatted_names = names(role, sep=", ", sep2=" and ", last_sep=", and ") - if as_sentence: - return sentence[formatted_names] - return formatted_names - - def format_eprint(self, e: Entry) -> Node: - if "doi" in e.fields: - return "" - return super().format_eprint(e) - - def format_url(self, e: Entry) -> Node: - if "doi" in e.fields or "eprint" in e.fields: - return "" - return words[ - href[ - field("url", raw=True), - field("url", raw=True, apply_func=remove_http), - ] - ] - - def format_isbn(self, e: Entry) -> Node: - return href[ - join[ - "https://isbnsearch.org/isbn/", - field("isbn", raw=True, apply_func=remove_dashes_and_spaces), - ], - join[ - "ISBN:", - field("isbn", raw=True), - ], - ] - - -def remove_dashes_and_spaces(isbn: str) -> str: - to_remove = ["-", " "] - for remove in to_remove: - isbn = isbn.replace(remove, "") - return isbn - - -def remove_http(url: str) -> str: - to_remove = ["https://", "http://"] - for remove in to_remove: - url = url.replace(remove, "") - return url - - -register_plugin("pybtex.style.formatting", "unsrt_et_al", MyStyle) diff --git a/pyproject.toml b/pyproject.toml index 3550222e..2659a8ce 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -74,6 +74,7 @@ doc = [ "sphinx-copybutton", "sphinx-design", "sphinx-hep-pdgref", + "sphinx-pybtex-etal-style", "sphinx-thebe", "sphinx-togglebutton", "sphinxcontrib-bibtex >=2.2", # bibtex_reference_style From 2a9fa4111c741f8276272eb7884e646f59c55662 Mon Sep 17 00:00:00 2001 From: Remco de Boer <29308176+redeboer@users.noreply.github.com> Date: Sat, 9 Dec 2023 17:28:05 +0100 Subject: [PATCH 10/20] DX: outsource `wiki` role to `sphinx-api-relink` --- docs/conf.py | 44 +------------------------------------------- pyproject.toml | 1 + 2 files changed, 2 insertions(+), 43 deletions(-) diff --git a/docs/conf.py b/docs/conf.py index c15ef62c..e82aa19d 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -13,16 +13,6 @@ import sys from datetime import datetime from functools import lru_cache -from typing import TYPE_CHECKING, Any - -from docutils import nodes - -if TYPE_CHECKING: - from docutils.nodes import Node as docutils_Node - from docutils.nodes import system_message - from docutils.parsers.rst.states import Inliner - from sphinx.application import Sphinx - from sphinx.util.typing import RoleFunction if sys.version_info < (3, 8): from importlib_metadata import PackageNotFoundError @@ -94,6 +84,7 @@ def get_repository_name() -> str: "sphinx.ext.todo", "sphinx.ext.viewcode", "sphinx_codeautolink", + "sphinx_api_relink", "sphinx_comments", "sphinx_copybutton", "sphinx_design", @@ -299,36 +290,3 @@ def print_once(message: str) -> None: "repository_url": html_theme_options["repository_url"], "repository_branch": html_theme_options["repository_branch"], } - - -# Add roles to simplify external links -def setup(app: Sphinx) -> dict[str, Any]: - app.add_role( - "wiki", - wikilink("https://en.wikipedia.org/wiki/%s"), - ) - return { - "parallel_read_safe": True, - "parallel_write_safe": True, - } - - -def wikilink(pattern: str) -> RoleFunction: - def role( # noqa: PLR0913 - name: str, - rawtext: str, - text: str, - lineno: int, - inliner: Inliner, - options: dict | None = None, - content: list[str] | None = None, - ) -> tuple[list[docutils_Node], list[system_message]]: - output_text = text - output_text = output_text.replace("_", " ") - url = pattern % (text,) - if options is None: - options = {} - reference_node = nodes.reference(rawtext, output_text, refuri=url, **options) - return [reference_node], [] - - return role diff --git a/pyproject.toml b/pyproject.toml index 2659a8ce..5882fbb7 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -68,6 +68,7 @@ doc = [ "matplotlib", "myst-nb >=0.11", # myst_enable_extensions "numpy <1.24", # bug in feynman: https://github.com/ComPWA/PWA-pages/actions/runs/3868808372/jobs/6594501436#step:6:177 + "sphinx-api-relink >=0.0.8", "sphinx-book-theme", "sphinx-codeautolink[ipython]", "sphinx-comments", From d39925fc9625fc7475c28d9d316fafb041361c9a Mon Sep 17 00:00:00 2001 From: Remco de Boer <29308176+redeboer@users.noreply.github.com> Date: Sat, 9 Dec 2023 18:41:51 +0100 Subject: [PATCH 11/20] MAINT: clean up `conf.py` with new Sphinx extensions --- docs/.gitignore | 1 + docs/conf.py | 286 +++++++++++++++--------------------------------- docs/index.md | 1 + pyproject.toml | 1 + tox.ini | 2 + 5 files changed, 92 insertions(+), 199 deletions(-) diff --git a/docs/.gitignore b/docs/.gitignore index 509b35a9..c0322827 100644 --- a/docs/.gitignore +++ b/docs/.gitignore @@ -1,5 +1,6 @@ *.doctree *.inv *build/ +api/ !_static/* diff --git a/docs/conf.py b/docs/conf.py index e82aa19d..05ceee5d 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -1,78 +1,75 @@ """Configuration file for the Sphinx documentation builder. This file only contains a selection of the most common options. For a full list see the -documentation: -https://www.sphinx-doc.org/en/master/usage/configuration.html +documentation: https://www.sphinx-doc.org/en/master/usage/configuration.html """ -# pyright: reportMissingImports=false from __future__ import annotations -import os -import re -import sys from datetime import datetime -from functools import lru_cache -if sys.version_info < (3, 8): - from importlib_metadata import PackageNotFoundError - from importlib_metadata import version as get_package_version -else: - from importlib.metadata import PackageNotFoundError - from importlib.metadata import version as get_package_version - -# -- Project information ----------------------------------------------------- -project = "PWA Software Pages" -PACKAGE = "pwa_pages" -copyright = "2020, ComPWA" # noqa: A001 -author = "Common Partial Wave Analysis" - - -def get_branch_name() -> str: - branch = os.environ.get("READTHEDOCS_VERSION") - if branch == "latest": - branch = "main" - if branch is None: - branch = os.environ.get("GITHUB_REF", "main") - branch = branch.replace("refs/heads/", "") # type: ignore[union-attr] - branch = branch.replace("refs/pull/", "") - branch = branch.replace("refs/tags/", "") - if re.match(r"^\d+/[a-z]+$", branch) is not None: # type: ignore[arg-type] - branch = "main" # PR preview - print(f" Branch name: {branch}") - return branch - - -def get_repository_name() -> str: - repo = os.environ.get("GITHUB_REPOSITORY", "ComPWA/PWA-pages") - print(f" Repository: {repo}") - return repo +from sphinx_api_relink.helpers import ( + get_branch_name, + get_execution_mode, + get_package_version, + pin, + pin_minor, + set_intersphinx_version_remapping, +) +set_intersphinx_version_remapping({ + "ipython": { + "8.12.2": "8.12.1", + "8.12.3": "8.12.1", + }, + "matplotlib": {"3.5.1": "3.5.0"}, +}) BRANCH = get_branch_name() -REPO_NAME = get_repository_name() - -try: - __VERSION = get_package_version(PACKAGE) - version = ".".join(__VERSION.split(".")[:3]) -except PackageNotFoundError: - pass - +ORGANIZATION = "ComPWA" +PACKAGE = "pwa_pages" +REPO_NAME = "PWA-pages" +REPO_TITLE = "PWA Software Pages" -# -- General configuration --------------------------------------------------- -master_doc = "index.md" -source_suffix = { - ".ipynb": "myst-nb", - ".md": "myst-nb", - ".rst": "restructuredtext", +add_module_names = False +api_github_repo = f"{ORGANIZATION}/{REPO_NAME}" +api_target_substitutions: dict[str, str | tuple[str, str]] = { + "datetime": "datetime.datetime", } - -# The master toctree document. -master_doc = "index" -modindex_common_prefix = [ - f"{PACKAGE}.", +author = "Common Partial Wave Analysis" +autodoc_default_options = { + "members": True, + "undoc-members": True, + "show-inheritance": True, + "special-members": ", ".join([ + "__call__", + "__eq__", + ]), +} +autosectionlabel_prefix_document = True +bibtex_bibfiles = ["bibliography.bib"] +bibtex_default_style = "unsrt_et_al" +bibtex_reference_style = "author_year" +codeautolink_concat_default = True +codeautolink_global_preface = """ +from IPython.display import display +""" +comments_config = { + "hypothesis": True, + "utterances": { + "repo": f"{ORGANIZATION}/{REPO_NAME}", + "issue-term": "pathname", + "label": "📝 Docs", + }, +} +copybutton_prompt_is_regexp = True +copybutton_prompt_text = r">>> |\.\.\. " # doctest +copyright = f"2020, {ORGANIZATION}" +default_role = "py:obj" +exclude_patterns = [ + "**.ipynb_checkpoints", + "*build", ] - extensions = [ "myst_nb", "sphinx.ext.autodoc", @@ -82,9 +79,8 @@ def get_repository_name() -> str: "sphinx.ext.mathjax", "sphinx.ext.napoleon", "sphinx.ext.todo", - "sphinx.ext.viewcode", - "sphinx_codeautolink", "sphinx_api_relink", + "sphinx_codeautolink", "sphinx_comments", "sphinx_copybutton", "sphinx_design", @@ -94,26 +90,7 @@ def get_repository_name() -> str: "sphinx_togglebutton", "sphinxcontrib.bibtex", ] -exclude_patterns = [ - "**.ipynb_checkpoints", - "*build", -] - -# General sphinx settings -add_module_names = False -autodoc_default_options = { - "members": True, - "undoc-members": True, - "show-inheritance": True, - "special-members": ", ".join([ - "__call__", - "__eq__", - ]), -} -codeautolink_concat_default = True -codeautolink_global_preface = """ -from IPython.display import display -""" +generate_apidoc_package_path = f"../src/{PACKAGE}" graphviz_output_format = "svg" html_copy_source = True # needed for download notebook button html_css_files = ["custom.css"] @@ -126,7 +103,7 @@ def get_repository_name() -> str: html_static_path = ["_static"] html_theme = "sphinx_book_theme" html_theme_options = { - "repository_url": f"https://github.com/{REPO_NAME}", + "repository_url": f"https://github.com/{ORGANIZATION}/{REPO_NAME}", "repository_branch": BRANCH, "path_to_docs": "docs", "use_download_button": True, @@ -142,91 +119,13 @@ def get_repository_name() -> str: }, } html_title = "Partial Wave Analysis" -pygments_style = "sphinx" -todo_include_todos = True -viewcode_follow_imported_members = True - -# Cross-referencing configuration -default_role = "py:obj" -primary_domain = "py" -nitpicky = True # warn if cross-references are missing - -# Intersphinx settings -version_remapping = { - "ipython": { - "8.12.2": "8.12.1", - "8.12.3": "8.12.1", - }, - "matplotlib": {"3.5.1": "3.5.0"}, -} - - -def get_version(package_name: str) -> str: - python_version = f"{sys.version_info.major}.{sys.version_info.minor}" - constraints_path = f"../.constraints/py{python_version}.txt" - package_name = package_name.lower() - with open(constraints_path) as stream: - constraints = stream.read() - for line in constraints.split("\n"): - line = line.split("#")[0] # remove comments - line = line.strip() - line = line.lower() - if not line.startswith(package_name): - continue - if not line: - continue - line_segments = tuple(line.split("==")) - if len(line_segments) != 2: # noqa: PLR2004 - continue - _, installed_version, *_ = line_segments - installed_version = installed_version.strip() - remapped_versions = version_remapping.get(package_name) - if remapped_versions is not None: - existing_version = remapped_versions.get(installed_version) - if existing_version is not None: - return existing_version - return installed_version - return "stable" - - -def get_minor_version(package_name: str) -> str: - installed_version = get_version(package_name) - if installed_version == "stable": - return installed_version - matches = re.match(r"^([0-9]+\.[0-9]+).*$", installed_version) - if matches is None: - msg = f"Could not find documentation for {package_name} v{installed_version}" - raise ValueError(msg) - return matches[1] - - intersphinx_mapping = { - "IPython": ( - f"https://ipython.readthedocs.io/en/{get_version('IPython')}", - None, - ), - "matplotlib": ( - f"https://matplotlib.org/{get_version('matplotlib')}", - None, - ), + "IPython": (f"https://ipython.readthedocs.io/en/{pin('IPython')}", None), + "matplotlib": (f"https://matplotlib.org/{pin('matplotlib')}", None), "python": ("https://docs.python.org/3", None), + "pydantic": (f"https://docs.pydantic.dev/{pin_minor('pydantic')}", None), "sympy": ("https://docs.sympy.org/latest", None), } - -# Settings for autosectionlabel -autosectionlabel_prefix_document = True - -# Settings for bibtex -bibtex_bibfiles = [ - "bibliography.bib", -] -bibtex_reference_style = "author_year" - -# Settings for copybutton -copybutton_prompt_is_regexp = True -copybutton_prompt_text = r">>> |\.\.\. " # doctest - -# Settings for linkcheck linkcheck_anchors = False linkcheck_ignore = [ "http://127.0.0.1:8000", @@ -236,31 +135,10 @@ def get_minor_version(package_name: str) -> str: "https://home.fnal.gov/~kutschke/Angdist/angdist.ps", "https://physique.cuso.ch", "https://suchung.web.cern.ch", + "https://www.bookfinder.com", ] - - -# Settings for myst_nb -def get_execution_mode() -> str: - if "FORCE_EXECUTE_NB" in os.environ: - print_once("\033[93;1mWill run ALL Jupyter notebooks!\033[0m") - return "force" - if "EXECUTE_NB" in os.environ: - return "cache" - return "off" - - -@lru_cache(maxsize=None) -def print_once(message: str) -> None: - print(message) - - -nb_execution_mode = get_execution_mode() -nb_execution_show_tb = True -nb_execution_timeout = -1 -nb_output_stderr = "remove" -nb_execution_show_tb = True - -# Settings for myst-parser +master_doc = "index" +modindex_common_prefix = [f"{PACKAGE}."] myst_enable_extensions = [ "amsmath", "colon_fence", @@ -274,19 +152,29 @@ def print_once(message: str) -> None: "repo": REPO_NAME, } myst_update_mathjax = False - -# Settings for sphinx_comments -comments_config = { - "hypothesis": True, - "utterances": { - "repo": f"ComPWA/{REPO_NAME}", - "issue-term": "pathname", - "label": "📝 Docs", - }, +nb_execution_mode = get_execution_mode() +nb_execution_show_tb = True +nb_execution_timeout = -1 +nb_output_stderr = "remove" +nitpick_ignore_regex = [ + (r"py:(class|obj)", "ConfigDict"), + (r"py:(class|obj)", "FieldInfo"), + (r"py:(class|obj)", "Model.__fields__"), + (r"py:(class|obj)", "pydantic.main.BaseModel"), +] +nitpicky = True +primary_domain = "py" +project = REPO_TITLE +pygments_style = "sphinx" +release = get_package_version(PACKAGE) +source_suffix = { + ".ipynb": "myst-nb", + ".md": "myst-nb", + ".rst": "restructuredtext", } - -# Settings for Thebe cell output thebe_config = { "repository_url": html_theme_options["repository_url"], "repository_branch": html_theme_options["repository_branch"], } +todo_include_todos = True +version = get_package_version(PACKAGE) diff --git a/docs/index.md b/docs/index.md index 86045568..5fa50821 100644 --- a/docs/index.md +++ b/docs/index.md @@ -47,6 +47,7 @@ analysis caption: Appendices hidden: --- +API glossary references ``` diff --git a/pyproject.toml b/pyproject.toml index 5882fbb7..6246bdd9 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -336,6 +336,7 @@ task-tags = ["cspell"] "S113", "T201", ] +"docs/conf.py" = ["A001"] "setup.py" = ["D100"] "src/pwa_pages/project_inventory.py" = [ "FA100", diff --git a/tox.ini b/tox.ini index 8b7df1df..cb7440a5 100644 --- a/tox.ini +++ b/tox.ini @@ -64,6 +64,7 @@ commands = --re-ignore docs/.*\.yaml \ --re-ignore docs/.*\.yml \ --re-ignore docs/_build/.* \ + --re-ignore docs/api \ --watch docs \ docs/ docs/_build/html description = @@ -108,6 +109,7 @@ commands = --re-ignore docs/.*\.yaml \ --re-ignore docs/.*\.yml \ --re-ignore docs/_build/.* \ + --re-ignore docs/api \ --watch docs \ docs/ docs/_build/html description = From 8695cab943566c7c03a7187c7ef58f4e3e46683c Mon Sep 17 00:00:00 2001 From: GitHub Date: Sat, 9 Dec 2023 17:45:16 +0000 Subject: [PATCH 12/20] MAINT: update pip constraints and pre-commit --- .constraints/py3.10.txt | 17 +++++++++++++++-- .constraints/py3.11.txt | 17 +++++++++++++++-- .constraints/py3.7.txt | 7 ++++--- .constraints/py3.8.txt | 17 +++++++++++++++-- .constraints/py3.9.txt | 17 +++++++++++++++-- 5 files changed, 64 insertions(+), 11 deletions(-) diff --git a/.constraints/py3.10.txt b/.constraints/py3.10.txt index acee7223..f32267a4 100644 --- a/.constraints/py3.10.txt +++ b/.constraints/py3.10.txt @@ -20,6 +20,7 @@ black==23.11.0 bleach==6.1.0 cachetools==5.3.2 cattrs==23.2.3 +cerberus==1.3.5 certifi==2023.11.17 cffi==1.16.0 cfgv==3.4.0 @@ -38,6 +39,7 @@ decorator==5.1.1 defusedxml==0.7.1 deprecated==1.2.14 distlib==0.3.7 +docopt==0.6.2 docstring-to-markdown==0.13 docutils==0.17.1 dominate==2.9.0 @@ -61,7 +63,7 @@ ipykernel==6.27.1 ipython==8.18.1 ipywidgets==8.1.1 isoduration==20.11.0 -isort==5.12.0 +isort==5.13.0 jedi==0.19.1 jinja2==3.1.2 json5==0.9.14 @@ -103,10 +105,11 @@ mypy==1.7.1 mypy-extensions==1.0.0 myst-nb==1.0.0 myst-parser==1.0.0 -nbclient==0.9.0 +nbclient==0.6.8 nbconvert==7.12.0 nbdime==4.0.1 nbformat==5.9.2 +nbmake==1.4.6 nest-asyncio==1.5.8 nodeenv==1.8.0 notebook==7.0.6 @@ -118,9 +121,13 @@ pandocfilters==1.5.0 parso==0.8.3 pathspec==0.11.2 pathvalidate==3.2.0 +pep517==0.13.1 pexpect==4.9.0 pillow==10.1.0 +pip-api==0.0.30 +pipreqs==0.4.13 platformdirs==4.1.0 +plette==0.4.4 pluggy==1.3.0 pre-commit==3.5.0 prometheus-client==0.19.0 @@ -159,6 +166,7 @@ qtpy==2.4.1 referencing==0.32.0 requests==2.31.0 requests-toolbelt==1.0.0 +requirementslib==3.0.0 rfc3339-validator==0.1.4 rfc3986-validator==0.1.1 rope==1.11.0 @@ -171,6 +179,7 @@ sniffio==1.3.0 snowballstemmer==2.2.0 soupsieve==2.5 sphinx==5.3.0 +sphinx-api-relink==0.0.8 sphinx-autobuild==2021.3.14 sphinx-book-theme==1.0.1 sphinx-codeautolink==0.15.0 @@ -178,6 +187,7 @@ sphinx-comments==0.0.3 sphinx-copybutton==0.5.2 sphinx-design==0.5.0 sphinx-hep-pdgref==0.2.0 +sphinx-pybtex-etal-style==0.0.2 sphinx-thebe==0.3.0 sphinx-togglebutton==0.3.2 sphinxcontrib-applehelp==1.0.7 @@ -196,6 +206,7 @@ tcolorpy==0.1.4 terminado==0.18.0 tinycss2==1.2.1 tomli==2.0.1 +tomlkit==0.12.3 tornado==6.4 tox==4.11.4 traitlets==5.14.0 @@ -217,8 +228,10 @@ websocket-client==1.7.0 wheel==0.42.0 widgetsnbextension==4.0.9 wrapt==1.16.0 +yarg==0.1.9 zipp==3.17.0 # The following packages are considered to be unsafe in a requirements file: +# pip # pwa-pages # setuptools diff --git a/.constraints/py3.11.txt b/.constraints/py3.11.txt index ed50055a..14f34502 100644 --- a/.constraints/py3.11.txt +++ b/.constraints/py3.11.txt @@ -20,6 +20,7 @@ black==23.11.0 bleach==6.1.0 cachetools==5.3.2 cattrs==23.2.3 +cerberus==1.3.5 certifi==2023.11.17 cffi==1.16.0 cfgv==3.4.0 @@ -38,6 +39,7 @@ decorator==5.1.1 defusedxml==0.7.1 deprecated==1.2.14 distlib==0.3.7 +docopt==0.6.2 docstring-to-markdown==0.13 docutils==0.17.1 dominate==2.9.0 @@ -60,7 +62,7 @@ ipykernel==6.27.1 ipython==8.18.1 ipywidgets==8.1.1 isoduration==20.11.0 -isort==5.12.0 +isort==5.13.0 jedi==0.19.1 jinja2==3.1.2 json5==0.9.14 @@ -102,10 +104,11 @@ mypy==1.7.1 mypy-extensions==1.0.0 myst-nb==1.0.0 myst-parser==1.0.0 -nbclient==0.9.0 +nbclient==0.6.8 nbconvert==7.12.0 nbdime==4.0.1 nbformat==5.9.2 +nbmake==1.4.6 nest-asyncio==1.5.8 nodeenv==1.8.0 notebook==7.0.6 @@ -117,9 +120,13 @@ pandocfilters==1.5.0 parso==0.8.3 pathspec==0.11.2 pathvalidate==3.2.0 +pep517==0.13.1 pexpect==4.9.0 pillow==10.1.0 +pip-api==0.0.30 +pipreqs==0.4.13 platformdirs==4.1.0 +plette==0.4.4 pluggy==1.3.0 pre-commit==3.5.0 prometheus-client==0.19.0 @@ -158,6 +165,7 @@ qtpy==2.4.1 referencing==0.32.0 requests==2.31.0 requests-toolbelt==1.0.0 +requirementslib==3.0.0 rfc3339-validator==0.1.4 rfc3986-validator==0.1.1 rope==1.11.0 @@ -170,6 +178,7 @@ sniffio==1.3.0 snowballstemmer==2.2.0 soupsieve==2.5 sphinx==5.3.0 +sphinx-api-relink==0.0.8 sphinx-autobuild==2021.3.14 sphinx-book-theme==1.0.1 sphinx-codeautolink==0.15.0 @@ -177,6 +186,7 @@ sphinx-comments==0.0.3 sphinx-copybutton==0.5.2 sphinx-design==0.5.0 sphinx-hep-pdgref==0.2.0 +sphinx-pybtex-etal-style==0.0.2 sphinx-thebe==0.3.0 sphinx-togglebutton==0.3.2 sphinxcontrib-applehelp==1.0.7 @@ -194,6 +204,7 @@ tabulate==0.9.0 tcolorpy==0.1.4 terminado==0.18.0 tinycss2==1.2.1 +tomlkit==0.12.3 tornado==6.4 tox==4.11.4 traitlets==5.14.0 @@ -215,8 +226,10 @@ websocket-client==1.7.0 wheel==0.42.0 widgetsnbextension==4.0.9 wrapt==1.16.0 +yarg==0.1.9 zipp==3.17.0 # The following packages are considered to be unsafe in a requirements file: +# pip # pwa-pages # setuptools diff --git a/.constraints/py3.7.txt b/.constraints/py3.7.txt index bb05c686..f7cd34eb 100644 --- a/.constraints/py3.7.txt +++ b/.constraints/py3.7.txt @@ -8,7 +8,6 @@ accessible-pygments==0.0.4 aiofiles==22.1.0 aiosqlite==0.19.0 alabaster==0.7.13 -annotated-types==0.5.0 anyio==3.7.1 argon2-cffi==23.1.0 argon2-cffi-bindings==21.2.0 @@ -112,6 +111,7 @@ nbclient==0.5.13 nbconvert==7.6.0 nbdime==3.2.1 nbformat==5.8.0 +nbmake==1.3.0 nest-asyncio==1.5.8 nodeenv==1.8.0 notebook==6.5.6 @@ -136,8 +136,7 @@ ptyprocess==0.7.0 pybtex==0.24.0 pybtex-docutils==1.0.3 pycparser==2.21 -pydantic==2.5.2 -pydantic-core==2.14.5 +pydantic==1.10.13 pydata-sphinx-theme==0.13.3 pygithub==2.1.1 pygments==2.17.2 @@ -175,6 +174,7 @@ sniffio==1.3.0 snowballstemmer==2.2.0 soupsieve==2.4.1 sphinx==5.3.0 +sphinx-api-relink==0.0.8 sphinx-autobuild==2021.3.14 sphinx-book-theme==1.0.1 sphinx-codeautolink==0.15.0 @@ -182,6 +182,7 @@ sphinx-comments==0.0.3 sphinx-copybutton==0.5.2 sphinx-design==0.4.1 sphinx-hep-pdgref==0.2.0 +sphinx-pybtex-etal-style==0.0.2 sphinx-thebe==0.2.1 sphinx-togglebutton==0.3.2 sphinxcontrib-applehelp==1.0.2 diff --git a/.constraints/py3.8.txt b/.constraints/py3.8.txt index 71133ca6..14316a5c 100644 --- a/.constraints/py3.8.txt +++ b/.constraints/py3.8.txt @@ -21,6 +21,7 @@ black==23.11.0 bleach==6.1.0 cachetools==5.3.2 cattrs==23.2.3 +cerberus==1.3.5 certifi==2023.11.17 cffi==1.16.0 cfgv==3.4.0 @@ -39,6 +40,7 @@ decorator==5.1.1 defusedxml==0.7.1 deprecated==1.2.14 distlib==0.3.7 +docopt==0.6.2 docstring-to-markdown==0.13 docutils==0.17.1 dominate==2.9.0 @@ -63,7 +65,7 @@ ipykernel==6.27.1 ipython==8.12.3 ipywidgets==8.1.1 isoduration==20.11.0 -isort==5.12.0 +isort==5.13.0 jedi==0.19.1 jinja2==3.1.2 json5==0.9.14 @@ -105,10 +107,11 @@ mypy==1.7.1 mypy-extensions==1.0.0 myst-nb==0.17.2 myst-parser==0.18.1 -nbclient==0.7.4 +nbclient==0.6.8 nbconvert==7.12.0 nbdime==4.0.1 nbformat==5.9.2 +nbmake==1.4.6 nest-asyncio==1.5.8 nodeenv==1.8.0 notebook==7.0.6 @@ -120,11 +123,15 @@ pandocfilters==1.5.0 parso==0.8.3 pathspec==0.11.2 pathvalidate==3.2.0 +pep517==0.13.1 pexpect==4.9.0 pickleshare==0.7.5 pillow==10.1.0 +pip-api==0.0.30 +pipreqs==0.4.13 pkgutil-resolve-name==1.3.10 platformdirs==4.1.0 +plette==0.4.4 pluggy==1.3.0 pre-commit==3.5.0 prometheus-client==0.19.0 @@ -163,6 +170,7 @@ qtpy==2.4.1 referencing==0.32.0 requests==2.31.0 requests-toolbelt==1.0.0 +requirementslib==3.0.0 rfc3339-validator==0.1.4 rfc3986-validator==0.1.1 rope==1.11.0 @@ -175,6 +183,7 @@ sniffio==1.3.0 snowballstemmer==2.2.0 soupsieve==2.5 sphinx==5.3.0 +sphinx-api-relink==0.0.8 sphinx-autobuild==2021.3.14 sphinx-book-theme==1.0.1 sphinx-codeautolink==0.15.0 @@ -182,6 +191,7 @@ sphinx-comments==0.0.3 sphinx-copybutton==0.5.2 sphinx-design==0.5.0 sphinx-hep-pdgref==0.2.0 +sphinx-pybtex-etal-style==0.0.2 sphinx-thebe==0.3.0 sphinx-togglebutton==0.3.2 sphinxcontrib-applehelp==1.0.4 @@ -200,6 +210,7 @@ tcolorpy==0.1.4 terminado==0.18.0 tinycss2==1.2.1 tomli==2.0.1 +tomlkit==0.12.3 tornado==6.4 tox==4.11.4 traitlets==5.14.0 @@ -221,8 +232,10 @@ websocket-client==1.7.0 wheel==0.42.0 widgetsnbextension==4.0.9 wrapt==1.16.0 +yarg==0.1.9 zipp==3.17.0 # The following packages are considered to be unsafe in a requirements file: +# pip # pwa-pages # setuptools diff --git a/.constraints/py3.9.txt b/.constraints/py3.9.txt index 4f410159..c01b0f5d 100644 --- a/.constraints/py3.9.txt +++ b/.constraints/py3.9.txt @@ -20,6 +20,7 @@ black==23.11.0 bleach==6.1.0 cachetools==5.3.2 cattrs==23.2.3 +cerberus==1.3.5 certifi==2023.11.17 cffi==1.16.0 cfgv==3.4.0 @@ -38,6 +39,7 @@ decorator==5.1.1 defusedxml==0.7.1 deprecated==1.2.14 distlib==0.3.7 +docopt==0.6.2 docstring-to-markdown==0.13 docutils==0.17.1 dominate==2.9.0 @@ -62,7 +64,7 @@ ipykernel==6.27.1 ipython==8.18.1 ipywidgets==8.1.1 isoduration==20.11.0 -isort==5.12.0 +isort==5.13.0 jedi==0.19.1 jinja2==3.1.2 json5==0.9.14 @@ -104,10 +106,11 @@ mypy==1.7.1 mypy-extensions==1.0.0 myst-nb==1.0.0 myst-parser==1.0.0 -nbclient==0.9.0 +nbclient==0.6.8 nbconvert==7.12.0 nbdime==4.0.1 nbformat==5.9.2 +nbmake==1.4.6 nest-asyncio==1.5.8 nodeenv==1.8.0 notebook==7.0.6 @@ -119,9 +122,13 @@ pandocfilters==1.5.0 parso==0.8.3 pathspec==0.11.2 pathvalidate==3.2.0 +pep517==0.13.1 pexpect==4.9.0 pillow==10.1.0 +pip-api==0.0.30 +pipreqs==0.4.13 platformdirs==4.1.0 +plette==0.4.4 pluggy==1.3.0 pre-commit==3.5.0 prometheus-client==0.19.0 @@ -160,6 +167,7 @@ qtpy==2.4.1 referencing==0.32.0 requests==2.31.0 requests-toolbelt==1.0.0 +requirementslib==3.0.0 rfc3339-validator==0.1.4 rfc3986-validator==0.1.1 rope==1.11.0 @@ -172,6 +180,7 @@ sniffio==1.3.0 snowballstemmer==2.2.0 soupsieve==2.5 sphinx==5.3.0 +sphinx-api-relink==0.0.8 sphinx-autobuild==2021.3.14 sphinx-book-theme==1.0.1 sphinx-codeautolink==0.15.0 @@ -179,6 +188,7 @@ sphinx-comments==0.0.3 sphinx-copybutton==0.5.2 sphinx-design==0.5.0 sphinx-hep-pdgref==0.2.0 +sphinx-pybtex-etal-style==0.0.2 sphinx-thebe==0.3.0 sphinx-togglebutton==0.3.2 sphinxcontrib-applehelp==1.0.7 @@ -197,6 +207,7 @@ tcolorpy==0.1.4 terminado==0.18.0 tinycss2==1.2.1 tomli==2.0.1 +tomlkit==0.12.3 tornado==6.4 tox==4.11.4 traitlets==5.14.0 @@ -218,8 +229,10 @@ websocket-client==1.7.0 wheel==0.42.0 widgetsnbextension==4.0.9 wrapt==1.16.0 +yarg==0.1.9 zipp==3.17.0 # The following packages are considered to be unsafe in a requirements file: +# pip # pwa-pages # setuptools From ac6118974198f177d835a357fba649acc7603d0d Mon Sep 17 00:00:00 2001 From: Remco de Boer <29308176+redeboer@users.noreply.github.com> Date: Sat, 9 Dec 2023 18:46:29 +0100 Subject: [PATCH 13/20] FIX: remove `importlib-metadata` from `doc` dependencies --- pyproject.toml | 1 - 1 file changed, 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 6246bdd9..57a2beff 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -80,7 +80,6 @@ doc = [ "sphinx-togglebutton", "sphinxcontrib-bibtex >=2.2", # bibtex_reference_style "sympy", - 'importlib-metadata; python_version <"3.8.0"', ] format = [ "black", From 22e6dc2bfbdf70c630cc16143e7e3d4c090bc8c6 Mon Sep 17 00:00:00 2001 From: Remco de Boer <29308176+redeboer@users.noreply.github.com> Date: Sat, 9 Dec 2023 18:47:48 +0100 Subject: [PATCH 14/20] FIX: install `sphinx-api-relink` in type hint deps --- pyproject.toml | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index 57a2beff..0295f893 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -81,9 +81,7 @@ doc = [ "sphinxcontrib-bibtex >=2.2", # bibtex_reference_style "sympy", ] -format = [ - "black", -] +format = ["black"] jupyter = [ "PWA-pages[doc]", "isort", @@ -102,6 +100,7 @@ lint = [ ] mypy = [ "mypy >=0.730", # error code support + "sphinx-api-relink >=0.0.8", "types-PyYAML", "types-docutils", "types-pkg-resources", From a596f7d23a5860ef6a7df9494aa4bdb69834d89e Mon Sep 17 00:00:00 2001 From: Remco de Boer <29308176+redeboer@users.noreply.github.com> Date: Sat, 9 Dec 2023 18:48:22 +0100 Subject: [PATCH 15/20] MAINT: remove `ypy-websocket` version constraints --- pyproject.toml | 1 - 1 file changed, 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 0295f893..b64a8504 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -92,7 +92,6 @@ jupyter = [ "jupyterlab-myst", "python-lsp-ruff", "python-lsp-server[rope]", - 'ypy-websocket <0.8.3; python_version <"3.8.0"', ] lint = [ "PWA-pages[mypy]", From 0bc689b741d44323b46f76e960052d8fb141c8b2 Mon Sep 17 00:00:00 2001 From: GitHub Date: Sat, 9 Dec 2023 17:49:56 +0000 Subject: [PATCH 16/20] MAINT: update pip constraints and pre-commit --- .constraints/py3.7.txt | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.constraints/py3.7.txt b/.constraints/py3.7.txt index f7cd34eb..ae2dc2cc 100644 --- a/.constraints/py3.7.txt +++ b/.constraints/py3.7.txt @@ -80,7 +80,7 @@ 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 +jupyter-ydoc==0.2.5 jupyterlab==3.6.6 jupyterlab-code-formatter==2.2.1 jupyterlab-git==0.44.0 @@ -222,8 +222,8 @@ websocket-client==1.6.1 wheel==0.42.0 widgetsnbextension==4.0.9 wrapt==1.16.0 -y-py==0.5.9 -ypy-websocket==0.8.2 +y-py==0.6.2 +ypy-websocket==0.8.4 zipp==3.15.0 # The following packages are considered to be unsafe in a requirements file: From b65dd5820365e636828d0db5278721da4d582663 Mon Sep 17 00:00:00 2001 From: Remco de Boer <29308176+redeboer@users.noreply.github.com> Date: Sat, 9 Dec 2023 18:49:59 +0100 Subject: [PATCH 17/20] MAINT: remove `docutils` version restriction --- pyproject.toml | 1 - 1 file changed, 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index b64a8504..71d9cf8b 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -61,7 +61,6 @@ dev = [ ] doc = [ "Sphinx >=3", - "docutils <0.18", # https://github.com/executablebooks/jupyter-book/issues/2026#issuecomment-1636657741 "feynman", "ipywidgets", "jupyter", From bdeb57960d9b38d1362f1cbaf08550c07e11d148 Mon Sep 17 00:00:00 2001 From: Remco de Boer <29308176+redeboer@users.noreply.github.com> Date: Sat, 9 Dec 2023 18:50:16 +0100 Subject: [PATCH 18/20] FIX: remove `numpy` version restriction --- pyproject.toml | 1 - 1 file changed, 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 71d9cf8b..57fde262 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -66,7 +66,6 @@ doc = [ "jupyter", "matplotlib", "myst-nb >=0.11", # myst_enable_extensions - "numpy <1.24", # bug in feynman: https://github.com/ComPWA/PWA-pages/actions/runs/3868808372/jobs/6594501436#step:6:177 "sphinx-api-relink >=0.0.8", "sphinx-book-theme", "sphinx-codeautolink[ipython]", From caf73cbd791d7e74ea287dafb266ec7404239e95 Mon Sep 17 00:00:00 2001 From: GitHub Date: Sat, 9 Dec 2023 17:55:57 +0000 Subject: [PATCH 19/20] MAINT: update pip constraints and pre-commit --- .constraints/py3.10.txt | 2 +- .constraints/py3.11.txt | 2 +- .constraints/py3.8.txt | 2 +- .constraints/py3.9.txt | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/.constraints/py3.10.txt b/.constraints/py3.10.txt index f32267a4..f6c787c4 100644 --- a/.constraints/py3.10.txt +++ b/.constraints/py3.10.txt @@ -114,7 +114,7 @@ nest-asyncio==1.5.8 nodeenv==1.8.0 notebook==7.0.6 notebook-shim==0.2.3 -numpy==1.23.5 +numpy==1.26.2 overrides==7.4.0 packaging==23.2 pandocfilters==1.5.0 diff --git a/.constraints/py3.11.txt b/.constraints/py3.11.txt index 14f34502..977c0e1c 100644 --- a/.constraints/py3.11.txt +++ b/.constraints/py3.11.txt @@ -113,7 +113,7 @@ nest-asyncio==1.5.8 nodeenv==1.8.0 notebook==7.0.6 notebook-shim==0.2.3 -numpy==1.23.5 +numpy==1.26.2 overrides==7.4.0 packaging==23.2 pandocfilters==1.5.0 diff --git a/.constraints/py3.8.txt b/.constraints/py3.8.txt index 14316a5c..b02dd4ee 100644 --- a/.constraints/py3.8.txt +++ b/.constraints/py3.8.txt @@ -116,7 +116,7 @@ nest-asyncio==1.5.8 nodeenv==1.8.0 notebook==7.0.6 notebook-shim==0.2.3 -numpy==1.23.5 +numpy==1.24.4 overrides==7.4.0 packaging==23.2 pandocfilters==1.5.0 diff --git a/.constraints/py3.9.txt b/.constraints/py3.9.txt index c01b0f5d..0ee9382d 100644 --- a/.constraints/py3.9.txt +++ b/.constraints/py3.9.txt @@ -115,7 +115,7 @@ nest-asyncio==1.5.8 nodeenv==1.8.0 notebook==7.0.6 notebook-shim==0.2.3 -numpy==1.23.5 +numpy==1.26.2 overrides==7.4.0 packaging==23.2 pandocfilters==1.5.0 From f3ff2379aff34e1dfdf3428b8260969326a5d800 Mon Sep 17 00:00:00 2001 From: Remco de Boer <29308176+redeboer@users.noreply.github.com> Date: Sat, 9 Dec 2023 18:58:35 +0100 Subject: [PATCH 20/20] FIX: set correct repo name --- docs/conf.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/conf.py b/docs/conf.py index 05ceee5d..02d3c60a 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -149,7 +149,7 @@ myst_substitutions = { "branch": BRANCH, "build_date": datetime.today().strftime("%d %B %Y"), - "repo": REPO_NAME, + "repo": f"{ORGANIZATION}/{REPO_NAME}", } myst_update_mathjax = False nb_execution_mode = get_execution_mode()