diff --git a/poetry.lock b/poetry.lock index ab52d3d..5fc0f68 100644 --- a/poetry.lock +++ b/poetry.lock @@ -1,10 +1,9 @@ -# This file is automatically @generated by Poetry and should not be changed by hand. +# This file is automatically @generated by Poetry 1.5.0 and should not be changed by hand. [[package]] name = "appnope" version = "0.1.3" description = "Disable App Nap on macOS >= 10.9" -category = "dev" optional = false python-versions = "*" files = [ @@ -16,7 +15,6 @@ files = [ name = "aspy-refactor-imports" version = "2.3.0" description = "Utilities for refactoring imports in python-like syntax." -category = "dev" optional = false python-versions = ">=3.7" files = [ @@ -31,7 +29,6 @@ cached-property = "*" name = "astroid" version = "2.11.7" description = "An abstract syntax tree for Python with inference support." -category = "dev" optional = false python-versions = ">=3.6.2" files = [ @@ -50,7 +47,6 @@ wrapt = ">=1.11,<2" name = "asttokens" version = "2.2.1" description = "Annotate AST trees with source code positions" -category = "dev" optional = false python-versions = "*" files = [ @@ -68,7 +64,6 @@ test = ["astroid", "pytest"] name = "atomicwrites" version = "1.4.1" description = "Atomic file writes." -category = "dev" optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" files = [ @@ -79,7 +74,6 @@ files = [ name = "attrs" version = "23.1.0" description = "Classes Without Boilerplate" -category = "main" optional = false python-versions = ">=3.7" files = [ @@ -101,7 +95,6 @@ tests-no-zope = ["cloudpickle", "hypothesis", "mypy (>=1.1.1)", "pympler", "pyte name = "backcall" version = "0.2.0" description = "Specifications for callback functions passed in to an API" -category = "dev" optional = false python-versions = "*" files = [ @@ -113,7 +106,6 @@ files = [ name = "backports-cached-property" version = "1.0.2" description = "cached_property() - computed once per instance, cached as attribute" -category = "main" optional = true python-versions = ">=3.6.0" files = [ @@ -125,7 +117,6 @@ files = [ name = "bandit" version = "1.7.5" description = "Security oriented static analyser for python code." -category = "dev" optional = false python-versions = ">=3.7" files = [ @@ -149,7 +140,6 @@ yaml = ["PyYAML"] name = "black" version = "22.12.0" description = "The uncompromising code formatter." -category = "dev" optional = false python-versions = ">=3.7" files = [ @@ -186,7 +176,6 @@ uvloop = ["uvloop (>=0.15.2)"] name = "blacken-docs" version = "1.13.0" description = "Run Black on Python code blocks in documentation files." -category = "dev" optional = false python-versions = ">=3.7" files = [ @@ -201,7 +190,6 @@ black = ">=22.1.0" name = "build" version = "0.10.0" description = "A simple, correct Python build frontend" -category = "main" optional = true python-versions = ">= 3.7" files = [ @@ -226,7 +214,6 @@ virtualenv = ["virtualenv (>=20.0.35)"] name = "cachecontrol" version = "0.12.11" description = "httplib2 caching for requests" -category = "main" optional = true python-versions = ">=3.6" files = [ @@ -247,7 +234,6 @@ redis = ["redis (>=2.10.5)"] name = "cached-property" version = "1.5.2" description = "A decorator for caching properties in classes." -category = "dev" optional = false python-versions = "*" files = [ @@ -255,11 +241,21 @@ files = [ {file = "cached_property-1.5.2-py2.py3-none-any.whl", hash = "sha256:df4f613cf7ad9a588cc381aaf4a512d26265ecebd5eb9e1ba12f1319eb85a6a0"}, ] +[[package]] +name = "cachetools" +version = "5.3.0" +description = "Extensible memoizing collections and decorators" +optional = false +python-versions = "~=3.7" +files = [ + {file = "cachetools-5.3.0-py3-none-any.whl", hash = "sha256:429e1a1e845c008ea6c85aa35d4b98b65d6a9763eeef3e37e92728a12d1de9d4"}, + {file = "cachetools-5.3.0.tar.gz", hash = "sha256:13dfddc7b8df938c21a940dfa6557ce6e94a2f1cdfa58eb90c805721d58f2c14"}, +] + [[package]] name = "certifi" version = "2023.5.7" description = "Python package for providing Mozilla's CA Bundle." -category = "main" optional = false python-versions = ">=3.6" files = [ @@ -271,7 +267,6 @@ files = [ name = "cffi" version = "1.15.1" description = "Foreign Function Interface for Python calling C code." -category = "main" optional = true python-versions = "*" files = [ @@ -348,7 +343,6 @@ pycparser = "*" name = "cfgv" version = "3.3.1" description = "Validate configuration and produce human readable error messages." -category = "dev" optional = false python-versions = ">=3.6.1" files = [ @@ -356,11 +350,21 @@ files = [ {file = "cfgv-3.3.1.tar.gz", hash = "sha256:f5a830efb9ce7a445376bb66ec94c638a9787422f96264c98edc6bdeed8ab736"}, ] +[[package]] +name = "chardet" +version = "5.1.0" +description = "Universal encoding detector for Python 3" +optional = false +python-versions = ">=3.7" +files = [ + {file = "chardet-5.1.0-py3-none-any.whl", hash = "sha256:362777fb014af596ad31334fde1e8c327dfdb076e1960d1694662d46a6917ab9"}, + {file = "chardet-5.1.0.tar.gz", hash = "sha256:0d62712b956bc154f85fb0a266e2a3c5913c2967e00348701b32411d6def31e5"}, +] + [[package]] name = "charset-normalizer" version = "3.1.0" description = "The Real First Universal Charset Detector. Open, modern and actively maintained alternative to Chardet." -category = "main" optional = false python-versions = ">=3.7.0" files = [ @@ -445,7 +449,6 @@ files = [ name = "cleo" version = "2.0.1" description = "Cleo allows you to create beautiful and testable command-line interfaces." -category = "main" optional = true python-versions = ">=3.7,<4.0" files = [ @@ -461,7 +464,6 @@ rapidfuzz = ">=2.2.0,<3.0.0" name = "click" version = "8.1.3" description = "Composable command line interface toolkit" -category = "dev" optional = false python-versions = ">=3.7" files = [ @@ -477,7 +479,6 @@ importlib-metadata = {version = "*", markers = "python_version < \"3.8\""} name = "colorama" version = "0.4.6" description = "Cross-platform colored terminal text." -category = "main" optional = false python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,!=3.5.*,!=3.6.*,>=2.7" files = [ @@ -489,7 +490,6 @@ files = [ name = "coverage" version = "7.2.5" description = "Code coverage measurement for Python" -category = "dev" optional = false python-versions = ">=3.7" files = [ @@ -553,7 +553,6 @@ toml = ["tomli"] name = "crashtest" version = "0.4.1" description = "Manage Python errors with ease" -category = "main" optional = true python-versions = ">=3.7,<4.0" files = [ @@ -565,7 +564,6 @@ files = [ name = "cryptography" version = "40.0.2" description = "cryptography is a package which provides cryptographic recipes and primitives to Python developers." -category = "main" optional = true python-versions = ">=3.6" files = [ @@ -607,7 +605,6 @@ tox = ["tox"] name = "decorator" version = "5.1.1" description = "Decorators for Humans" -category = "dev" optional = false python-versions = ">=3.5" files = [ @@ -619,7 +616,6 @@ files = [ name = "dill" version = "0.3.6" description = "serialize all of python" -category = "dev" optional = false python-versions = ">=3.7" files = [ @@ -634,7 +630,6 @@ graph = ["objgraph (>=1.7.2)"] name = "distlib" version = "0.3.6" description = "Distribution utilities" -category = "main" optional = false python-versions = "*" files = [ @@ -646,7 +641,6 @@ files = [ name = "dparse" version = "0.6.2" description = "A parser for Python dependency files" -category = "dev" optional = false python-versions = ">=3.5" files = [ @@ -666,7 +660,6 @@ pipenv = ["pipenv"] name = "dulwich" version = "0.21.5" description = "Python Git Library" -category = "main" optional = true python-versions = ">=3.7" files = [ @@ -742,7 +735,6 @@ pgp = ["gpg"] name = "executing" version = "1.2.0" description = "Get the currently executing AST node of a frame, and other information" -category = "dev" optional = false python-versions = "*" files = [ @@ -757,7 +749,6 @@ tests = ["asttokens", "littleutils", "pytest", "rich"] name = "filelock" version = "3.12.0" description = "A platform independent file lock." -category = "main" optional = false python-versions = ">=3.7" files = [ @@ -773,7 +764,6 @@ testing = ["covdefaults (>=2.3)", "coverage (>=7.2.3)", "diff-cover (>=7.5)", "p name = "gitdb" version = "4.0.10" description = "Git Object Database" -category = "dev" optional = false python-versions = ">=3.7" files = [ @@ -788,7 +778,6 @@ smmap = ">=3.0.1,<6" name = "gitpython" version = "3.1.31" description = "GitPython is a Python library used to interact with Git repositories" -category = "dev" optional = false python-versions = ">=3.7" files = [ @@ -804,7 +793,6 @@ typing-extensions = {version = ">=3.7.4.3", markers = "python_version < \"3.8\"" name = "html5lib" version = "1.1" description = "HTML parser based on the WHATWG HTML specification" -category = "main" optional = true python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" files = [ @@ -826,7 +814,6 @@ lxml = ["lxml"] name = "identify" version = "2.5.24" description = "File identification library for Python" -category = "dev" optional = false python-versions = ">=3.7" files = [ @@ -841,7 +828,6 @@ license = ["ukkonen"] name = "idna" version = "3.4" description = "Internationalized Domain Names in Applications (IDNA)" -category = "main" optional = false python-versions = ">=3.5" files = [ @@ -853,7 +839,6 @@ files = [ name = "importlib-metadata" version = "6.6.0" description = "Read metadata from Python packages" -category = "main" optional = false python-versions = ">=3.7" files = [ @@ -874,7 +859,6 @@ testing = ["flake8 (<5)", "flufl.flake8", "importlib-resources (>=1.3)", "packag name = "importlib-resources" version = "5.12.0" description = "Read resources from Python packages" -category = "main" optional = true python-versions = ">=3.7" files = [ @@ -893,7 +877,6 @@ testing = ["flake8 (<5)", "pytest (>=6)", "pytest-black (>=0.3.7)", "pytest-chec name = "iniconfig" version = "2.0.0" description = "brain-dead simple config-ini parsing" -category = "dev" optional = false python-versions = ">=3.7" files = [ @@ -905,7 +888,6 @@ files = [ name = "installer" version = "0.7.0" description = "A library for installing Python wheels." -category = "main" optional = true python-versions = ">=3.7" files = [ @@ -917,7 +899,6 @@ files = [ name = "ipython" version = "8.12.2" description = "IPython: Productive Interactive Computing" -category = "dev" optional = false python-versions = ">=3.8" files = [ @@ -957,7 +938,6 @@ test-extra = ["curio", "matplotlib (!=3.2.0)", "nbformat", "numpy (>=1.21)", "pa name = "isort" version = "5.11.5" description = "A Python utility / library to sort Python imports." -category = "dev" optional = false python-versions = ">=3.7.0" files = [ @@ -975,7 +955,6 @@ requirements-deprecated-finder = ["pip-api", "pipreqs"] name = "jaraco-classes" version = "3.2.3" description = "Utility functions for Python class constructs" -category = "main" optional = true python-versions = ">=3.7" files = [ @@ -994,7 +973,6 @@ testing = ["flake8 (<5)", "pytest (>=6)", "pytest-black (>=0.3.7)", "pytest-chec name = "jedi" version = "0.18.2" description = "An autocompletion tool for Python that can be used for text editors." -category = "dev" optional = false python-versions = ">=3.6" files = [ @@ -1014,7 +992,6 @@ testing = ["Django (<3.1)", "attrs", "colorama", "docopt", "pytest (<7.0.0)"] name = "jeepney" version = "0.8.0" description = "Low-level, pure Python DBus protocol wrapper." -category = "main" optional = true python-versions = ">=3.7" files = [ @@ -1030,7 +1007,6 @@ trio = ["async_generator", "trio"] name = "jsonschema" version = "4.17.3" description = "An implementation of JSON Schema validation for Python" -category = "main" optional = true python-versions = ">=3.7" files = [ @@ -1054,7 +1030,6 @@ format-nongpl = ["fqdn", "idna", "isoduration", "jsonpointer (>1.13)", "rfc3339- name = "keyring" version = "23.13.1" description = "Store and access your passwords safely." -category = "main" optional = true python-versions = ">=3.7" files = [ @@ -1079,7 +1054,6 @@ testing = ["flake8 (<5)", "pytest (>=6)", "pytest-black (>=0.3.7)", "pytest-chec name = "lazy-object-proxy" version = "1.9.0" description = "A fast and thorough lazy object proxy." -category = "dev" optional = false python-versions = ">=3.7" files = [ @@ -1125,7 +1099,6 @@ files = [ name = "linkify-it-py" version = "2.0.2" description = "Links recognition library with FULL unicode support." -category = "dev" optional = false python-versions = ">=3.7" files = [ @@ -1146,7 +1119,6 @@ test = ["coverage", "pytest", "pytest-cov"] name = "lockfile" version = "0.12.2" description = "Platform-independent file locking module" -category = "main" optional = true python-versions = "*" files = [ @@ -1158,7 +1130,6 @@ files = [ name = "markdown-it-py" version = "2.2.0" description = "Python port of markdown-it. Markdown parsing, done right!" -category = "dev" optional = false python-versions = ">=3.7" files = [ @@ -1185,7 +1156,6 @@ testing = ["coverage", "pytest", "pytest-cov", "pytest-regressions"] name = "matplotlib-inline" version = "0.1.6" description = "Inline Matplotlib backend for Jupyter" -category = "dev" optional = false python-versions = ">=3.5" files = [ @@ -1200,7 +1170,6 @@ traitlets = "*" name = "mccabe" version = "0.7.0" description = "McCabe checker, plugin for flake8" -category = "dev" optional = false python-versions = ">=3.6" files = [ @@ -1212,7 +1181,6 @@ files = [ name = "mdformat" version = "0.7.16" description = "CommonMark compliant Markdown formatter" -category = "dev" optional = false python-versions = ">=3.7" files = [ @@ -1230,7 +1198,6 @@ typing-extensions = {version = ">=3.7.4", markers = "python_version < \"3.8\""} name = "mdformat-gfm" version = "0.3.5" description = "Mdformat plugin for GitHub Flavored Markdown compatibility" -category = "dev" optional = false python-versions = ">=3.7,<4.0" files = [ @@ -1248,7 +1215,6 @@ mdit-py-plugins = ">=0.2.0,<0.4.0" name = "mdformat-tables" version = "0.4.1" description = "An mdformat plugin for rendering tables." -category = "dev" optional = false python-versions = ">=3.6.1" files = [ @@ -1266,7 +1232,6 @@ test = ["coverage", "pytest (>=6.0,<7.0)", "pytest-cov"] name = "mdit-py-plugins" version = "0.3.5" description = "Collection of plugins for markdown-it-py" -category = "dev" optional = false python-versions = ">=3.7" files = [ @@ -1286,7 +1251,6 @@ testing = ["coverage", "pytest", "pytest-cov", "pytest-regressions"] name = "mdurl" version = "0.1.2" description = "Markdown URL utilities" -category = "dev" optional = false python-versions = ">=3.7" files = [ @@ -1298,7 +1262,6 @@ files = [ name = "more-itertools" version = "9.1.0" description = "More routines for operating on iterables, beyond itertools" -category = "main" optional = true python-versions = ">=3.7" files = [ @@ -1310,7 +1273,6 @@ files = [ name = "msgpack" version = "1.0.5" description = "MessagePack serializer" -category = "main" optional = true python-versions = "*" files = [ @@ -1383,7 +1345,6 @@ files = [ name = "mypy" version = "0.930" description = "Optional static typing for Python" -category = "dev" optional = false python-versions = ">=3.6" files = [ @@ -1423,7 +1384,6 @@ python2 = ["typed-ast (>=1.4.0,<2)"] name = "mypy-extensions" version = "1.0.0" description = "Type system extensions for programs checked with the mypy type checker." -category = "dev" optional = false python-versions = ">=3.5" files = [ @@ -1435,7 +1395,6 @@ files = [ name = "nodeenv" version = "1.8.0" description = "Node.js virtual environment builder" -category = "dev" optional = false python-versions = ">=2.7,!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,!=3.5.*,!=3.6.*" files = [ @@ -1448,24 +1407,19 @@ setuptools = "*" [[package]] name = "packaging" -version = "21.3" +version = "23.1" description = "Core utilities for Python packages" -category = "main" optional = false -python-versions = ">=3.6" +python-versions = ">=3.7" files = [ - {file = "packaging-21.3-py3-none-any.whl", hash = "sha256:ef103e05f519cdc783ae24ea4e2e0f508a9c99b2d4969652eed6a2e1ea5bd522"}, - {file = "packaging-21.3.tar.gz", hash = "sha256:dd47c42927d89ab911e606518907cc2d3a1f38bbd026385970643f9c5b8ecfeb"}, + {file = "packaging-23.1-py3-none-any.whl", hash = "sha256:994793af429502c4ea2ebf6bf664629d07c1a9fe974af92966e4b8d2df7edc61"}, + {file = "packaging-23.1.tar.gz", hash = "sha256:a392980d2b6cffa644431898be54b0045151319d1e7ec34f0cfed48767dd334f"}, ] -[package.dependencies] -pyparsing = ">=2.0.2,<3.0.5 || >3.0.5" - [[package]] name = "parso" version = "0.8.3" description = "A Python Parser" -category = "dev" optional = false python-versions = ">=3.6" files = [ @@ -1481,7 +1435,6 @@ testing = ["docopt", "pytest (<6.0.0)"] name = "pathspec" version = "0.11.1" description = "Utility library for gitignore style pattern matching of file paths." -category = "dev" optional = false python-versions = ">=3.7" files = [ @@ -1493,7 +1446,6 @@ files = [ name = "pbr" version = "5.11.1" description = "Python Build Reasonableness" -category = "dev" optional = false python-versions = ">=2.6" files = [ @@ -1505,7 +1457,6 @@ files = [ name = "pexpect" version = "4.8.0" description = "Pexpect allows easy control of interactive console applications." -category = "main" optional = false python-versions = "*" files = [ @@ -1520,7 +1471,6 @@ ptyprocess = ">=0.5" name = "pickleshare" version = "0.7.5" description = "Tiny 'shelve'-like database with concurrency support" -category = "dev" optional = false python-versions = "*" files = [ @@ -1532,7 +1482,6 @@ files = [ name = "pkginfo" version = "1.9.6" description = "Query metadata from sdists / bdists / installed packages." -category = "main" optional = true python-versions = ">=3.6" files = [ @@ -1547,7 +1496,6 @@ testing = ["pytest", "pytest-cov"] name = "pkgutil-resolve-name" version = "1.3.10" description = "Resolve a name to an object." -category = "main" optional = true python-versions = ">=3.6" files = [ @@ -1557,28 +1505,26 @@ files = [ [[package]] name = "platformdirs" -version = "2.6.2" +version = "3.5.1" description = "A small Python package for determining appropriate platform-specific dirs, e.g. a \"user data dir\"." -category = "main" optional = false python-versions = ">=3.7" files = [ - {file = "platformdirs-2.6.2-py3-none-any.whl", hash = "sha256:83c8f6d04389165de7c9b6f0c682439697887bca0aa2f1c87ef1826be3584490"}, - {file = "platformdirs-2.6.2.tar.gz", hash = "sha256:e1fea1fe471b9ff8332e229df3cb7de4f53eeea4998d3b6bfff542115e998bd2"}, + {file = "platformdirs-3.5.1-py3-none-any.whl", hash = "sha256:e2378146f1964972c03c085bb5662ae80b2b8c06226c54b2ff4aa9483e8a13a5"}, + {file = "platformdirs-3.5.1.tar.gz", hash = "sha256:412dae91f52a6f84830f39a8078cecd0e866cb72294a5c66808e74d5e88d251f"}, ] [package.dependencies] -typing-extensions = {version = ">=4.4", markers = "python_version < \"3.8\""} +typing-extensions = {version = ">=4.5", markers = "python_version < \"3.8\""} [package.extras] -docs = ["furo (>=2022.12.7)", "proselint (>=0.13)", "sphinx (>=5.3)", "sphinx-autodoc-typehints (>=1.19.5)"] -test = ["appdirs (==1.4.4)", "covdefaults (>=2.2.2)", "pytest (>=7.2)", "pytest-cov (>=4)", "pytest-mock (>=3.10)"] +docs = ["furo (>=2023.3.27)", "proselint (>=0.13)", "sphinx (>=6.2.1)", "sphinx-autodoc-typehints (>=1.23,!=1.23.4)"] +test = ["appdirs (==1.4.4)", "covdefaults (>=2.3)", "pytest (>=7.3.1)", "pytest-cov (>=4)", "pytest-mock (>=3.10)"] [[package]] name = "pluggy" version = "1.0.0" description = "plugin and hook calling mechanisms for python" -category = "main" optional = false python-versions = ">=3.6" files = [ @@ -1595,14 +1541,13 @@ testing = ["pytest", "pytest-benchmark"] [[package]] name = "poetry" -version = "1.4.2" +version = "1.5.0" description = "Python dependency management and packaging made easy." -category = "main" optional = true python-versions = ">=3.7,<4.0" files = [ - {file = "poetry-1.4.2-py3-none-any.whl", hash = "sha256:c39c483cde7930915c992f932c163994ce3d870765efb8235ad0139cd65f0c5b"}, - {file = "poetry-1.4.2.tar.gz", hash = "sha256:0bd580a42482579635e774c5286ef73b8df3427567123cdb128b286cec671b3c"}, + {file = "poetry-1.5.0-py3-none-any.whl", hash = "sha256:e66c728b3c645a12c24f553a3e60f3b1ee425aa4a09c331dd372ff14e0976d26"}, + {file = "poetry-1.5.0.tar.gz", hash = "sha256:4fc7d37cf400739dcfcbb666db97fd74c46eaae119dd6ed9c8d5dd7e32c6f06a"}, ] [package.dependencies] @@ -1622,33 +1567,29 @@ lockfile = ">=0.12.2,<0.13.0" packaging = ">=20.4" pexpect = ">=4.7.0,<5.0.0" pkginfo = ">=1.9.4,<2.0.0" -platformdirs = ">=2.5.2,<3.0.0" -poetry-core = "1.5.2" -poetry-plugin-export = ">=1.3.0,<2.0.0" +platformdirs = ">=3.0.0,<4.0.0" +poetry-core = "1.6.0" +poetry-plugin-export = ">=1.3.1,<2.0.0" pyproject-hooks = ">=1.0.0,<2.0.0" requests = ">=2.18,<3.0" -requests-toolbelt = ">=0.9.1,<0.11.0" +requests-toolbelt = ">=0.9.1,<2" shellingham = ">=1.5,<2.0" tomli = {version = ">=2.0.1,<3.0.0", markers = "python_version < \"3.11\""} -tomlkit = ">=0.11.1,<0.11.2 || >0.11.2,<0.11.3 || >0.11.3,<1.0.0" +tomlkit = ">=0.11.4,<1.0.0" trove-classifiers = ">=2022.5.19" urllib3 = ">=1.26.0,<2.0.0" -virtualenv = [ - {version = ">=20.4.3,<20.4.5 || >20.4.5,<20.4.6 || >20.4.6,<21.0.0", markers = "sys_platform != \"win32\" or python_version != \"3.9\""}, - {version = ">=20.4.3,<20.4.5 || >20.4.5,<20.4.6 || >20.4.6,<20.16.6", markers = "sys_platform == \"win32\" and python_version == \"3.9\""}, -] +virtualenv = ">=20.22.0,<21.0.0" xattr = {version = ">=0.10.0,<0.11.0", markers = "sys_platform == \"darwin\""} [[package]] name = "poetry-core" -version = "1.5.2" +version = "1.6.0" description = "Poetry PEP 517 Build Backend" -category = "main" optional = false python-versions = ">=3.7,<4.0" files = [ - {file = "poetry_core-1.5.2-py3-none-any.whl", hash = "sha256:832d40a1ea5fd10c0f648d0575cadddc8b79f06f91d83a1f1a73a7e1dfacfbd7"}, - {file = "poetry_core-1.5.2.tar.gz", hash = "sha256:c6556c3b1ec5b8668e6ef5a4494726bc41d31907339425e194e78a6178436c14"}, + {file = "poetry_core-1.6.0-py3-none-any.whl", hash = "sha256:ff96620579f02ec30ee9f789fa5dfdcddd9ab4ac848394f6f8f2f4e88306b534"}, + {file = "poetry_core-1.6.0.tar.gz", hash = "sha256:a9c7296a12d6c8e4f8aa50a66ef3c967b2b50fba634da144d358e676fad9989f"}, ] [package.dependencies] @@ -1658,7 +1599,6 @@ importlib-metadata = {version = ">=1.7.0", markers = "python_version < \"3.8\""} name = "poetry-plugin-export" version = "1.3.1" description = "Poetry plugin to export the dependencies to various formats" -category = "main" optional = true python-versions = ">=3.7,<4.0" files = [ @@ -1674,7 +1614,6 @@ poetry-core = ">=1.3.0,<2.0.0" name = "pre-commit" version = "2.21.0" description = "A framework for managing and maintaining multi-language pre-commit hooks." -category = "dev" optional = false python-versions = ">=3.7" files = [ @@ -1694,7 +1633,6 @@ virtualenv = ">=20.10.0" name = "pre-commit-hooks" version = "3.4.0" description = "Some out-of-the-box hooks for pre-commit." -category = "dev" optional = false python-versions = ">=3.6.1" files = [ @@ -1710,7 +1648,6 @@ toml = "*" name = "prompt-toolkit" version = "3.0.38" description = "Library for building powerful interactive command lines in Python" -category = "dev" optional = false python-versions = ">=3.7.0" files = [ @@ -1725,7 +1662,6 @@ wcwidth = "*" name = "ptyprocess" version = "0.7.0" description = "Run a subprocess in a pseudo terminal" -category = "main" optional = false python-versions = "*" files = [ @@ -1737,7 +1673,6 @@ files = [ name = "pure-eval" version = "0.2.2" description = "Safely evaluate AST nodes without side effects" -category = "dev" optional = false python-versions = "*" files = [ @@ -1752,7 +1687,6 @@ tests = ["pytest"] name = "py" version = "1.11.0" description = "library with cross-python path, ini-parsing, io, code, log facilities" -category = "main" optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" files = [ @@ -1764,7 +1698,6 @@ files = [ name = "pycparser" version = "2.21" description = "C parser in Python" -category = "main" optional = true python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" files = [ @@ -1776,7 +1709,6 @@ files = [ name = "pygments" version = "2.15.1" description = "Pygments is a syntax highlighting package written in Python." -category = "dev" optional = false python-versions = ">=3.7" files = [ @@ -1791,7 +1723,6 @@ plugins = ["importlib-metadata"] name = "pylint" version = "2.13.9" description = "python code static checker" -category = "dev" optional = false python-versions = ">=3.6.2" files = [ @@ -1813,25 +1744,28 @@ typing-extensions = {version = ">=3.10.0", markers = "python_version < \"3.10\"" testutil = ["gitpython (>3)"] [[package]] -name = "pyparsing" -version = "3.0.9" -description = "pyparsing module - Classes and methods to define and execute parsing grammars" -category = "main" +name = "pyproject-api" +version = "1.5.1" +description = "API to interact with the python pyproject.toml based projects" optional = false -python-versions = ">=3.6.8" +python-versions = ">=3.7" files = [ - {file = "pyparsing-3.0.9-py3-none-any.whl", hash = "sha256:5026bae9a10eeaefb61dab2f09052b9f4307d44aee4eda64b309723d8d206bbc"}, - {file = "pyparsing-3.0.9.tar.gz", hash = "sha256:2b020ecf7d21b687f219b71ecad3631f644a47f01403fa1d1036b0c6416d70fb"}, + {file = "pyproject_api-1.5.1-py3-none-any.whl", hash = "sha256:4698a3777c2e0f6b624f8a4599131e2a25376d90fe8d146d7ac74c67c6f97c43"}, + {file = "pyproject_api-1.5.1.tar.gz", hash = "sha256:435f46547a9ff22cf4208ee274fca3e2869aeb062a4834adfc99a4dd64af3cf9"}, ] +[package.dependencies] +packaging = ">=23" +tomli = {version = ">=2.0.1", markers = "python_version < \"3.11\""} + [package.extras] -diagrams = ["jinja2", "railroad-diagrams"] +docs = ["furo (>=2022.12.7)", "sphinx (>=6.1.3)", "sphinx-autodoc-typehints (>=1.22,!=1.23.4)"] +testing = ["covdefaults (>=2.2.2)", "importlib-metadata (>=6)", "pytest (>=7.2.1)", "pytest-cov (>=4)", "pytest-mock (>=3.10)", "virtualenv (>=20.17.1)", "wheel (>=0.38.4)"] [[package]] name = "pyproject-hooks" version = "1.0.0" description = "Wrappers to call pyproject.toml-based build backend hooks." -category = "main" optional = true python-versions = ">=3.7" files = [ @@ -1846,7 +1780,6 @@ tomli = {version = ">=1.1.0", markers = "python_version < \"3.11\""} name = "pyrsistent" version = "0.19.3" description = "Persistent/Functional/Immutable data structures" -category = "main" optional = true python-versions = ">=3.7" files = [ @@ -1883,7 +1816,6 @@ files = [ name = "pytest" version = "6.2.5" description = "pytest: simple powerful testing with Python" -category = "dev" optional = false python-versions = ">=3.6" files = [ @@ -1909,7 +1841,6 @@ testing = ["argcomplete", "hypothesis (>=3.56)", "mock", "nose", "requests", "xm name = "pytest-cov" version = "2.12.1" description = "Pytest plugin for measuring coverage." -category = "dev" optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" files = [ @@ -1929,7 +1860,6 @@ testing = ["fields", "hunter", "process-tests", "pytest-xdist", "six", "virtuale name = "pywin32-ctypes" version = "0.2.0" description = "" -category = "main" optional = true python-versions = "*" files = [ @@ -1941,7 +1871,6 @@ files = [ name = "pyyaml" version = "6.0" description = "YAML parser and emitter for Python" -category = "dev" optional = false python-versions = ">=3.6" files = [ @@ -1991,7 +1920,6 @@ files = [ name = "rapidfuzz" version = "2.15.1" description = "rapid fuzzy string matching" -category = "main" optional = true python-versions = ">=3.7" files = [ @@ -2096,7 +2024,6 @@ full = ["numpy"] name = "reorder-python-imports" version = "2.8.0" description = "Tool for reordering python imports" -category = "dev" optional = false python-versions = ">=3.7" files = [ @@ -2109,14 +2036,13 @@ files = [ [[package]] name = "requests" -version = "2.30.0" +version = "2.31.0" description = "Python HTTP for Humans." -category = "main" optional = false python-versions = ">=3.7" files = [ - {file = "requests-2.30.0-py3-none-any.whl", hash = "sha256:10e94cc4f3121ee6da529d358cdaeaff2f1c409cd377dbc72b825852f2f7e294"}, - {file = "requests-2.30.0.tar.gz", hash = "sha256:239d7d4458afcb28a692cdd298d87542235f4ca8d36d03a15bfc128a6559a2f4"}, + {file = "requests-2.31.0-py3-none-any.whl", hash = "sha256:58cd2187c01e70e6e26505bca751777aa9f2ee0b7f4300988b709f44e013003f"}, + {file = "requests-2.31.0.tar.gz", hash = "sha256:942c5a758f98d790eaed1a29cb6eefc7ffb0d1cf7af05c3d2791656dbd6ad1e1"}, ] [package.dependencies] @@ -2131,14 +2057,13 @@ use-chardet-on-py3 = ["chardet (>=3.0.2,<6)"] [[package]] name = "requests-toolbelt" -version = "0.10.1" +version = "1.0.0" description = "A utility belt for advanced users of python-requests" -category = "main" optional = true python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" files = [ - {file = "requests-toolbelt-0.10.1.tar.gz", hash = "sha256:62e09f7ff5ccbda92772a29f394a49c3ad6cb181d568b1337626b2abb628a63d"}, - {file = "requests_toolbelt-0.10.1-py2.py3-none-any.whl", hash = "sha256:18565aa58116d9951ac39baa288d3adb5b3ff975c4f25eee78555d89e8f247f7"}, + {file = "requests-toolbelt-1.0.0.tar.gz", hash = "sha256:7681a0a3d047012b5bdc0ee37d7f8f07ebe76ab08caeccfc3921ce23c88d5bc6"}, + {file = "requests_toolbelt-1.0.0-py2.py3-none-any.whl", hash = "sha256:cccfdd665f0a24fcf4726e690f65639d272bb0637b9b92dfd91a5568ccf6bd06"}, ] [package.dependencies] @@ -2148,7 +2073,6 @@ requests = ">=2.0.1,<3.0.0" name = "rich" version = "13.3.5" description = "Render rich text, tables, progress bars, syntax highlighting, markdown and more to the terminal" -category = "dev" optional = false python-versions = ">=3.7.0" files = [ @@ -2168,7 +2092,6 @@ jupyter = ["ipywidgets (>=7.5.1,<9)"] name = "ruamel-yaml" version = "0.17.26" description = "ruamel.yaml is a YAML parser/emitter that supports roundtrip preservation of comments, seq/map flow style, and map key order" -category = "dev" optional = false python-versions = ">=3" files = [ @@ -2187,7 +2110,6 @@ jinja2 = ["ruamel.yaml.jinja2 (>=0.2)"] name = "ruamel-yaml-clib" version = "0.2.7" description = "C version of reader, parser and emitter for ruamel.yaml derived from libyaml" -category = "dev" optional = false python-versions = ">=3.5" files = [ @@ -2198,7 +2120,8 @@ files = [ {file = "ruamel.yaml.clib-0.2.7-cp310-cp310-win32.whl", hash = "sha256:763d65baa3b952479c4e972669f679fe490eee058d5aa85da483ebae2009d231"}, {file = "ruamel.yaml.clib-0.2.7-cp310-cp310-win_amd64.whl", hash = "sha256:d000f258cf42fec2b1bbf2863c61d7b8918d31ffee905da62dede869254d3b8a"}, {file = "ruamel.yaml.clib-0.2.7-cp311-cp311-macosx_10_9_universal2.whl", hash = "sha256:045e0626baf1c52e5527bd5db361bc83180faaba2ff586e763d3d5982a876a9e"}, - {file = "ruamel.yaml.clib-0.2.7-cp311-cp311-macosx_12_6_arm64.whl", hash = "sha256:721bc4ba4525f53f6a611ec0967bdcee61b31df5a56801281027a3a6d1c2daf5"}, + {file = "ruamel.yaml.clib-0.2.7-cp311-cp311-macosx_13_0_arm64.whl", hash = "sha256:1a6391a7cabb7641c32517539ca42cf84b87b667bad38b78d4d42dd23e957c81"}, + {file = "ruamel.yaml.clib-0.2.7-cp311-cp311-manylinux2014_aarch64.whl", hash = "sha256:9c7617df90c1365638916b98cdd9be833d31d337dbcd722485597b43c4a215bf"}, {file = "ruamel.yaml.clib-0.2.7-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.manylinux_2_24_x86_64.whl", hash = "sha256:41d0f1fa4c6830176eef5b276af04c89320ea616655d01327d5ce65e50575c94"}, {file = "ruamel.yaml.clib-0.2.7-cp311-cp311-win32.whl", hash = "sha256:f6d3d39611ac2e4f62c3128a9eed45f19a6608670c5a2f4f07f24e8de3441d38"}, {file = "ruamel.yaml.clib-0.2.7-cp311-cp311-win_amd64.whl", hash = "sha256:da538167284de58a52109a9b89b8f6a53ff8437dd6dc26d33b57bf6699153122"}, @@ -2231,20 +2154,19 @@ files = [ [[package]] name = "safety" -version = "2.3.5" +version = "2.3.4" description = "Checks installed dependencies for known vulnerabilities and licenses." -category = "dev" optional = false python-versions = "*" files = [ - {file = "safety-2.3.5-py3-none-any.whl", hash = "sha256:2227fcac1b22b53c1615af78872b48348661691450aa25d6704a5504dbd1f7e2"}, - {file = "safety-2.3.5.tar.gz", hash = "sha256:a60c11f8952f412cbb165d70cb1f673a3b43a2ba9a93ce11f97e6a4de834aa3a"}, + {file = "safety-2.3.4-py3-none-any.whl", hash = "sha256:6224dcd9b20986a2b2c5e7acfdfba6bca42bb11b2783b24ed04f32317e5167ea"}, + {file = "safety-2.3.4.tar.gz", hash = "sha256:b9e74e794e82f54d11f4091c5d820c4d2d81de9f953bf0b4f33ac8bc402ae72c"}, ] [package.dependencies] Click = ">=8.0.2" dparse = ">=0.6.2" -packaging = ">=21.0,<22.0" +packaging = ">=21.0" requests = "*" "ruamel.yaml" = ">=0.17.21" setuptools = ">=19.3" @@ -2257,7 +2179,6 @@ gitlab = ["python-gitlab (>=1.3.0)"] name = "secretstorage" version = "3.3.3" description = "Python bindings to FreeDesktop.org Secret Service API" -category = "main" optional = true python-versions = ">=3.6" files = [ @@ -2271,26 +2192,24 @@ jeepney = ">=0.6" [[package]] name = "setuptools" -version = "67.7.2" +version = "67.8.0" description = "Easily download, build, install, upgrade, and uninstall Python packages" -category = "dev" optional = false python-versions = ">=3.7" files = [ - {file = "setuptools-67.7.2-py3-none-any.whl", hash = "sha256:23aaf86b85ca52ceb801d32703f12d77517b2556af839621c641fca11287952b"}, - {file = "setuptools-67.7.2.tar.gz", hash = "sha256:f104fa03692a2602fa0fec6c6a9e63b6c8a968de13e17c026957dd1f53d80990"}, + {file = "setuptools-67.8.0-py3-none-any.whl", hash = "sha256:5df61bf30bb10c6f756eb19e7c9f3b473051f48db77fddbe06ff2ca307df9a6f"}, + {file = "setuptools-67.8.0.tar.gz", hash = "sha256:62642358adc77ffa87233bc4d2354c4b2682d214048f500964dbe760ccedf102"}, ] [package.extras] docs = ["furo", "jaraco.packaging (>=9)", "jaraco.tidelift (>=1.4)", "pygments-github-lexers (==0.0.5)", "rst.linker (>=1.9)", "sphinx (>=3.5)", "sphinx-favicon", "sphinx-hoverxref (<2)", "sphinx-inline-tabs", "sphinx-lint", "sphinx-notfound-page (==0.8.3)", "sphinx-reredirects", "sphinxcontrib-towncrier"] -testing = ["build[virtualenv]", "filelock (>=3.4.0)", "flake8 (<5)", "flake8-2020", "ini2toml[lite] (>=0.9)", "jaraco.envs (>=2.2)", "jaraco.path (>=3.2.0)", "pip (>=19.1)", "pip-run (>=8.8)", "pytest (>=6)", "pytest-black (>=0.3.7)", "pytest-checkdocs (>=2.4)", "pytest-cov", "pytest-enabler (>=1.3)", "pytest-flake8", "pytest-mypy (>=0.9.1)", "pytest-perf", "pytest-timeout", "pytest-xdist", "tomli-w (>=1.0.0)", "virtualenv (>=13.0.0)", "wheel"] +testing = ["build[virtualenv]", "filelock (>=3.4.0)", "flake8-2020", "ini2toml[lite] (>=0.9)", "jaraco.envs (>=2.2)", "jaraco.path (>=3.2.0)", "pip (>=19.1)", "pip-run (>=8.8)", "pytest (>=6)", "pytest-black (>=0.3.7)", "pytest-checkdocs (>=2.4)", "pytest-cov", "pytest-enabler (>=1.3)", "pytest-mypy (>=0.9.1)", "pytest-perf", "pytest-ruff", "pytest-timeout", "pytest-xdist", "tomli-w (>=1.0.0)", "virtualenv (>=13.0.0)", "wheel"] testing-integration = ["build[virtualenv]", "filelock (>=3.4.0)", "jaraco.envs (>=2.2)", "jaraco.path (>=3.2.0)", "pytest", "pytest-enabler", "pytest-xdist", "tomli", "virtualenv (>=13.0.0)", "wheel"] [[package]] name = "shellingham" version = "1.5.0.post1" description = "Tool to Detect Surrounding Shell" -category = "main" optional = true python-versions = ">=3.7" files = [ @@ -2302,7 +2221,6 @@ files = [ name = "six" version = "1.16.0" description = "Python 2 and 3 compatibility utilities" -category = "main" optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*" files = [ @@ -2314,7 +2232,6 @@ files = [ name = "smmap" version = "5.0.0" description = "A pure Python implementation of a sliding window memory map manager" -category = "dev" optional = false python-versions = ">=3.6" files = [ @@ -2326,7 +2243,6 @@ files = [ name = "stack-data" version = "0.6.2" description = "Extract data from python stack frames and tracebacks for informative displays" -category = "dev" optional = false python-versions = "*" files = [ @@ -2346,7 +2262,6 @@ tests = ["cython", "littleutils", "pygments", "pytest", "typeguard"] name = "stevedore" version = "3.5.2" description = "Manage dynamic plugins for Python applications" -category = "dev" optional = false python-versions = ">=3.6" files = [ @@ -2362,7 +2277,6 @@ pbr = ">=2.0.0,<2.1.0 || >2.1.0" name = "toml" version = "0.10.2" description = "Python Library for Tom's Obvious, Minimal Language" -category = "dev" optional = false python-versions = ">=2.6, !=3.0.*, !=3.1.*, !=3.2.*" files = [ @@ -2374,7 +2288,6 @@ files = [ name = "tomli" version = "2.0.1" description = "A lil' TOML parser" -category = "main" optional = false python-versions = ">=3.7" files = [ @@ -2386,7 +2299,6 @@ files = [ name = "tomlkit" version = "0.11.8" description = "Style preserving TOML library" -category = "main" optional = true python-versions = ">=3.7" files = [ @@ -2396,36 +2308,37 @@ files = [ [[package]] name = "tox" -version = "3.28.0" +version = "4.5.1" description = "tox is a generic virtualenv management and test command line tool" -category = "main" optional = false -python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,>=2.7" +python-versions = ">=3.7" files = [ - {file = "tox-3.28.0-py2.py3-none-any.whl", hash = "sha256:57b5ab7e8bb3074edc3c0c0b4b192a4f3799d3723b2c5b76f1fa9f2d40316eea"}, - {file = "tox-3.28.0.tar.gz", hash = "sha256:d0d28f3fe6d6d7195c27f8b054c3e99d5451952b54abdae673b71609a581f640"}, + {file = "tox-4.5.1-py3-none-any.whl", hash = "sha256:d25a2e6cb261adc489604fafd76cd689efeadfa79709965e965668d6d3f63046"}, + {file = "tox-4.5.1.tar.gz", hash = "sha256:5a2eac5fb816779dfdf5cb00fecbc27eb0524e4626626bb1de84747b24cacc56"}, ] [package.dependencies] -colorama = {version = ">=0.4.1", markers = "platform_system == \"Windows\""} -filelock = ">=3.0.0" -importlib-metadata = {version = ">=0.12", markers = "python_version < \"3.8\""} -packaging = ">=14" -pluggy = ">=0.12.0" -py = ">=1.4.17" -six = ">=1.14.0" -tomli = {version = ">=2.0.1", markers = "python_version >= \"3.7\" and python_version < \"3.11\""} -virtualenv = ">=16.0.0,<20.0.0 || >20.0.0,<20.0.1 || >20.0.1,<20.0.2 || >20.0.2,<20.0.3 || >20.0.3,<20.0.4 || >20.0.4,<20.0.5 || >20.0.5,<20.0.6 || >20.0.6,<20.0.7 || >20.0.7" +cachetools = ">=5.3" +chardet = ">=5.1" +colorama = ">=0.4.6" +filelock = ">=3.11" +importlib-metadata = {version = ">=6.4.1", markers = "python_version < \"3.8\""} +packaging = ">=23.1" +platformdirs = ">=3.2" +pluggy = ">=1" +pyproject-api = ">=1.5.1" +tomli = {version = ">=2.0.1", markers = "python_version < \"3.11\""} +typing-extensions = {version = ">=4.5", markers = "python_version < \"3.8\""} +virtualenv = ">=20.21" [package.extras] -docs = ["pygments-github-lexers (>=0.0.5)", "sphinx (>=2.0.0)", "sphinxcontrib-autoprogram (>=0.1.5)", "towncrier (>=18.5.0)"] -testing = ["flaky (>=3.4.0)", "freezegun (>=0.3.11)", "pathlib2 (>=2.3.3)", "psutil (>=5.6.1)", "pytest (>=4.0.0)", "pytest-cov (>=2.5.1)", "pytest-mock (>=1.10.0)", "pytest-randomly (>=1.0.0)"] +docs = ["furo (>=2023.3.27)", "sphinx (>=6.1.3)", "sphinx-argparse-cli (>=1.11)", "sphinx-autodoc-typehints (>=1.23,!=1.23.4)", "sphinx-copybutton (>=0.5.2)", "sphinx-inline-tabs (>=2022.1.2b11)", "sphinxcontrib-towncrier (>=0.2.1a0)", "towncrier (>=22.12)"] +testing = ["build[virtualenv] (>=0.10)", "covdefaults (>=2.3)", "devpi-process (>=0.3)", "diff-cover (>=7.5)", "distlib (>=0.3.6)", "flaky (>=3.7)", "hatch-vcs (>=0.3)", "hatchling (>=1.14)", "psutil (>=5.9.4)", "pytest (>=7.3.1)", "pytest-cov (>=4)", "pytest-mock (>=3.10)", "pytest-xdist (>=3.2.1)", "re-assert (>=1.1)", "time-machine (>=2.9)", "wheel (>=0.40)"] [[package]] name = "traitlets" version = "5.9.0" description = "Traitlets Python configuration system" -category = "dev" optional = false python-versions = ">=3.7" files = [ @@ -2441,7 +2354,6 @@ test = ["argcomplete (>=2.0)", "pre-commit", "pytest", "pytest-mock"] name = "trove-classifiers" version = "2023.5.2" description = "Canonical source for classifiers on PyPI (pypi.org)." -category = "main" optional = true python-versions = "*" files = [ @@ -2453,7 +2365,6 @@ files = [ name = "typed-ast" version = "1.5.4" description = "a fork of Python 2 and 3 ast modules with type comment support" -category = "dev" optional = false python-versions = ">=3.6" files = [ @@ -2487,7 +2398,6 @@ files = [ name = "types-toml" version = "0.10.8.6" description = "Typing stubs for toml" -category = "dev" optional = false python-versions = "*" files = [ @@ -2499,7 +2409,6 @@ files = [ name = "typing-extensions" version = "4.5.0" description = "Backported and Experimental Type Hints for Python 3.7+" -category = "main" optional = false python-versions = ">=3.7" files = [ @@ -2511,7 +2420,6 @@ files = [ name = "uc-micro-py" version = "1.0.2" description = "Micro subset of unicode data files for linkify-it-py projects." -category = "dev" optional = false python-versions = ">=3.7" files = [ @@ -2526,7 +2434,6 @@ test = ["coverage", "pytest", "pytest-cov"] name = "urllib3" version = "1.26.15" description = "HTTP library with thread-safe connection pooling, file post, and more." -category = "main" optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*, !=3.5.*" files = [ @@ -2541,32 +2448,29 @@ socks = ["PySocks (>=1.5.6,!=1.5.7,<2.0)"] [[package]] name = "virtualenv" -version = "20.15.1" +version = "20.23.0" description = "Virtual Python Environment builder" -category = "main" optional = false -python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,>=2.7" +python-versions = ">=3.7" files = [ - {file = "virtualenv-20.15.1-py2.py3-none-any.whl", hash = "sha256:b30aefac647e86af6d82bfc944c556f8f1a9c90427b2fb4e3bfbf338cb82becf"}, - {file = "virtualenv-20.15.1.tar.gz", hash = "sha256:288171134a2ff3bfb1a2f54f119e77cd1b81c29fc1265a2356f3e8d14c7d58c4"}, + {file = "virtualenv-20.23.0-py3-none-any.whl", hash = "sha256:6abec7670e5802a528357fdc75b26b9f57d5d92f29c5462ba0fbe45feacc685e"}, + {file = "virtualenv-20.23.0.tar.gz", hash = "sha256:a85caa554ced0c0afbd0d638e7e2d7b5f92d23478d05d17a76daeac8f279f924"}, ] [package.dependencies] -distlib = ">=0.3.1,<1" -filelock = ">=3.2,<4" -importlib-metadata = {version = ">=0.12", markers = "python_version < \"3.8\""} -platformdirs = ">=2,<3" -six = ">=1.9.0,<2" +distlib = ">=0.3.6,<1" +filelock = ">=3.11,<4" +importlib-metadata = {version = ">=6.4.1", markers = "python_version < \"3.8\""} +platformdirs = ">=3.2,<4" [package.extras] -docs = ["proselint (>=0.10.2)", "sphinx (>=3)", "sphinx-argparse (>=0.2.5)", "sphinx-rtd-theme (>=0.4.3)", "towncrier (>=21.3)"] -testing = ["coverage (>=4)", "coverage-enable-subprocess (>=1)", "flaky (>=3)", "packaging (>=20.0)", "pytest (>=4)", "pytest-env (>=0.6.2)", "pytest-freezegun (>=0.4.1)", "pytest-mock (>=2)", "pytest-randomly (>=1)", "pytest-timeout (>=1)"] +docs = ["furo (>=2023.3.27)", "proselint (>=0.13)", "sphinx (>=6.1.3)", "sphinx-argparse (>=0.4)", "sphinxcontrib-towncrier (>=0.2.1a0)", "towncrier (>=22.12)"] +test = ["covdefaults (>=2.3)", "coverage (>=7.2.3)", "coverage-enable-subprocess (>=1)", "flaky (>=3.7)", "packaging (>=23.1)", "pytest (>=7.3.1)", "pytest-env (>=0.8.1)", "pytest-freezegun (>=0.4.2)", "pytest-mock (>=3.10)", "pytest-randomly (>=3.12)", "pytest-timeout (>=2.1)", "setuptools (>=67.7.1)", "time-machine (>=2.9)"] [[package]] name = "wcwidth" version = "0.2.6" description = "Measures the displayed width of unicode strings in a terminal" -category = "dev" optional = false python-versions = "*" files = [ @@ -2578,7 +2482,6 @@ files = [ name = "webencodings" version = "0.5.1" description = "Character encoding aliases for legacy web content" -category = "main" optional = true python-versions = "*" files = [ @@ -2590,7 +2493,6 @@ files = [ name = "wrapt" version = "1.15.0" description = "Module for decorators, wrappers and monkey patching." -category = "dev" optional = false python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,>=2.7" files = [ @@ -2675,7 +2577,6 @@ files = [ name = "xattr" version = "0.10.1" description = "Python wrapper for extended filesystem attributes" -category = "main" optional = true python-versions = "*" files = [ @@ -2760,7 +2661,6 @@ cffi = ">=1.0" name = "zipp" version = "3.15.0" description = "Backport of pathlib-compatible object wrapper for zip files" -category = "main" optional = false python-versions = ">=3.7" files = [ @@ -2773,9 +2673,9 @@ docs = ["furo", "jaraco.packaging (>=9)", "jaraco.tidelift (>=1.4)", "rst.linker testing = ["big-O", "flake8 (<5)", "jaraco.functools", "jaraco.itertools", "more-itertools", "pytest (>=6)", "pytest-black (>=0.3.7)", "pytest-checkdocs (>=2.4)", "pytest-cov", "pytest-enabler (>=1.3)", "pytest-flake8", "pytest-mypy (>=0.9.1)"] [extras] -poetry = ["poetry", "cleo"] +poetry = ["cleo", "poetry"] [metadata] lock-version = "2.0" python-versions = "^3.7" -content-hash = "0a7ebe72f992c6dd6d03ed571866836a48fcf1b3a5d210aa9bcb5021776b1693" +content-hash = "eb94af731fc7a03914b50c82819a5a766687fbd75274a8c676ea9e5c9f416308" diff --git a/pyproject.toml b/pyproject.toml index 2d99fb3..d341527 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -40,9 +40,9 @@ poetry = ["poetry", "cleo"] [tool.poetry.dependencies] python = "^3.7" cleo = {version = ">=1.0,<3.0", optional = true} -poetry = {version = ">=1.2.0,<1.5.0", optional = true} +poetry = {version = "^1.5.0", optional = true} poetry-core = "^1.1.0" -tox = "^3.8.0" +tox = "^4" [tool.poetry.group.dev.dependencies] bandit = "^1.6.2" @@ -60,13 +60,8 @@ pytest-cov = "^2.10.1" reorder-python-imports = "^2.3.5" safety = "^2.2.0" toml = "^0.10.1" -tox = "^3.20.0" +tox = "^4" types-toml = "^0.10.1" -# This is a workaround for this issue with the Poetry export -# plugin which was blocking the 'security' CI check: -# -# https://github.com/python-poetry/poetry-plugin-export/issues/176 -virtualenv = ">=20.15,<20.16" [build-system] requires = ["poetry-core>=1.1.0"] diff --git a/tests/fixtures.py b/tests/fixtures.py index e50633a..9bf3b72 100644 --- a/tests/fixtures.py +++ b/tests/fixtures.py @@ -1,13 +1,14 @@ # pylint: disable=missing-module-docstring, missing-function-docstring, unused-argument, too-few-public-methods import time from pathlib import Path +from typing import List import poetry.factory -import poetry.installation.pip_installer +import poetry.installation.executor import poetry.utils.env import pytest -import tox -from poetry.core.packages.package import Package as PoetryPackage +import tox.tox_env.python.virtual_env.runner +from poetry.installation.operations.operation import Operation from tox_poetry_installer import utilities @@ -20,11 +21,8 @@ FAKE_VENV_PATH = Path("nowhere") class MockVirtualEnv: """Mock class for the :class:`poetry.utils.env.VirtualEnv` and :class:`tox.venv.VirtualEnv`""" - class MockTestenvConfig: # pylint: disable=missing-class-docstring - envdir = FAKE_VENV_PATH - def __init__(self, *args, **kwargs): - self.envconfig = self.MockTestenvConfig() + self.env_dir = FAKE_VENV_PATH self.installed = [] @staticmethod @@ -36,24 +34,24 @@ class MockVirtualEnv: return (1, 2, 3) -class MockPipInstaller: - """Mock class for the :class:`poetry.installation.pip_installer.PipInstaller`""" +class MockExecutor: + """Mock class for the :class:`poetry.installation.executor.Executor`""" def __init__(self, env: MockVirtualEnv, **kwargs): self.env = env - def install(self, package: PoetryPackage): - self.env.installed.append(package) + def execute(self, operations: List[Operation]): + self.env.installed.extend([operation.package for operation in operations]) time.sleep(1) @pytest.fixture def mock_venv(monkeypatch): monkeypatch.setattr(utilities, "convert_virtualenv", lambda venv: venv) + monkeypatch.setattr(poetry.installation.executor, "Executor", MockExecutor) monkeypatch.setattr( - poetry.installation.pip_installer, "PipInstaller", MockPipInstaller + tox.tox_env.python.virtual_env.runner, "VirtualEnvRunner", MockVirtualEnv ) - monkeypatch.setattr(tox.venv, "VirtualEnv", MockVirtualEnv) monkeypatch.setattr(poetry.utils.env, "VirtualEnv", MockVirtualEnv) diff --git a/tests/test_installer.py b/tests/test_installer.py index fa6073d..517879c 100644 --- a/tests/test_installer.py +++ b/tests/test_installer.py @@ -3,7 +3,7 @@ import time from unittest import mock import pytest -import tox.venv +import tox.tox_env.python.virtual_env.runner from poetry.factory import Factory from .fixtures import mock_poetry_factory @@ -19,7 +19,7 @@ def test_deduplication(mock_venv, mock_poetry_factory): item.name: item for item in poetry.locker.locked_repository().packages } - venv = tox.venv.VirtualEnv() + venv = tox.tox_env.python.virtual_env.runner.VirtualEnvRunner() to_install = [packages["toml"], packages["toml"]] installer.install(poetry, venv, to_install) @@ -43,12 +43,12 @@ def test_parallelization(mock_venv, mock_poetry_factory): packages["attrs"], ] - venv_sequential = tox.venv.VirtualEnv() + venv_sequential = tox.tox_env.python.virtual_env.runner.VirtualEnvRunner() start_sequential = time.time() installer.install(poetry, venv_sequential, to_install, 0) sequential = time.time() - start_sequential - venv_parallel = tox.venv.VirtualEnv() + venv_parallel = tox.tox_env.python.virtual_env.runner.VirtualEnvRunner() start_parallel = time.time() installer.install(poetry, venv_parallel, to_install, 5) parallel = time.time() - start_parallel @@ -76,13 +76,13 @@ def test_propagates_exceptions_during_installation( item.name: item for item in poetry.locker.locked_repository().packages } to_install = [packages["toml"]] - venv = tox.venv.VirtualEnv() + venv = tox.tox_env.python.virtual_env.runner.VirtualEnvRunner() fake_exception = ValueError("my testing exception") with mock.patch.object( _poetry, - "PipInstaller", - **{"return_value.install.side_effect": fake_exception}, + "Executor", + **{"return_value.execute.side_effect": fake_exception}, ): with pytest.raises(ValueError) as exc_info: installer.install(poetry, venv, to_install, num_threads) diff --git a/tox.ini b/tox.ini index 06dce0c..e271141 100644 --- a/tox.ini +++ b/tox.ini @@ -1,6 +1,5 @@ [tox] envlist = py37, py38, py39, py310, py311, static, static-tests, security -isolated_build = true skip_missing_interpreters = true [testenv] @@ -21,7 +20,7 @@ commands = [testenv:static] description = Static formatting and quality enforcement -basepython = python3.10 +basepython = py310 platform = linux ignore_errors = true locked_deps = @@ -46,7 +45,7 @@ commands = [testenv:static-tests] description = Static formatting and quality enforcement for the tests -basepython = python3.10 +basepython = py310 platform = linux ignore_errors = true locked_deps = @@ -63,7 +62,7 @@ commands = [testenv:security] description = Security checks -basepython = python3.10 +basepython = py310 platform = linux ignore_errors = true skip_install = true diff --git a/tox_poetry_installer/__init__.py b/tox_poetry_installer/__init__.py index 7e22471..5043b97 100644 --- a/tox_poetry_installer/__init__.py +++ b/tox_poetry_installer/__init__.py @@ -1,3 +1,4 @@ # pylint: disable=missing-docstring -from tox_poetry_installer.hooks import tox_addoption -from tox_poetry_installer.hooks import tox_testenv_install_deps +from tox_poetry_installer.hooks import tox_add_env_config +from tox_poetry_installer.hooks import tox_add_option +from tox_poetry_installer.hooks import tox_on_install diff --git a/tox_poetry_installer/_poetry.py b/tox_poetry_installer/_poetry.py index 7aa7b50..0ee72e5 100644 --- a/tox_poetry_installer/_poetry.py +++ b/tox_poetry_installer/_poetry.py @@ -29,8 +29,12 @@ from tox_poetry_installer import exceptions try: from cleo.io.null_io import NullIO + from poetry.config.config import Config + from poetry.core.packages.dependency import Dependency as PoetryDependency + from poetry.core.packages.package import Package as PoetryPackage from poetry.factory import Factory - from poetry.installation.pip_installer import PipInstaller + from poetry.installation.executor import Executor + from poetry.installation.operations.install import Install from poetry.poetry import Poetry from poetry.utils.env import VirtualEnv except ImportError: diff --git a/tox_poetry_installer/hooks.py b/tox_poetry_installer/hooks.py index ef1ed31..172178d 100644 --- a/tox_poetry_installer/hooks.py +++ b/tox_poetry_installer/hooks.py @@ -5,14 +5,13 @@ specifically related to implementing the hooks (to keep the size/readability of themselves manageable). """ from itertools import chain -from typing import Optional +from typing import List -import tox -from tox.action import Action as ToxAction -from tox.config import Parser as ToxParser -from tox.venv import VirtualEnv as ToxVirtualEnv +from tox.config.cli.parser import ToxParser +from tox.config.sets import EnvConfigSet +from tox.plugin import impl +from tox.tox_env.api import ToxEnv as ToxVirtualEnv -from tox_poetry_installer import __about__ from tox_poetry_installer import constants from tox_poetry_installer import exceptions from tox_poetry_installer import installer @@ -20,74 +19,9 @@ from tox_poetry_installer import logger from tox_poetry_installer import utilities -def _postprocess_install_project_deps( - testenv_config, value: Optional[str] # pylint: disable=unused-argument -) -> Optional[bool]: - """An awful hack to patch on three-state boolean logic to a config parameter - - .. warning: This logic should 100% be removed in the next feature release. It's here to work - around a bad design for now but should not persist. - - The bug filed in `#61`_ is caused by a combination of poor design and attempted cleverness. The - name of the ``install_project_deps`` config option implies that it has ultimate control over - whether the project dependencies are installed to the testenv, but this is not actually correct. - What it actually allows the user to do is force the project dependencies to not be installed to - an environment that would otherwise install them. This was intended behavior, however the - intention was wrong. - - .. _`#61`: https://github.com/enpaul/tox-poetry-installer/issues/61 - - In an effort to be clever the plugin automatically skips installing project dependencies when - the project package is not installed to the testenv (``skip_install = true``) or if packaging - as a whole is disabled (``skipsdist = true``). The intention of this behavior is to install only - the expected dependencies to a testenv and no more. However, this conflicts with the - ``install_project_deps`` config option, which cannot override this behavior because it defaults - to ``True``. In effect, ``install_project_deps = true`` in fact means "automatically - determine whether to install project dependencies" and ``install_project_deps = false`` means - "never install the project dependencies". This is not ideal and unintuitive. - - To avoid having to make a breaking change this workaround has been added to support three-state - logic between ``True``, ``False``, and ``None``. The ``install_project_deps`` option is now - parsed by Tox as a string with a default value of ``None``. If the value is not ``None`` then - this post processing function will try to convert it to a boolean the same way that Tox's - `SectionReader.getbool()`_ method does, raising an error to mimic the default behavior if it - can't. - - .. _`SectionReader.getbool()`: https://github.com/tox-dev/tox/blob/f8459218ee5ab5753321b3eb989b7beee5b391ad/src/tox/config/__init__.py#L1724 - - The three states for the ``install_project_deps`` setting are: - * ``None`` - User did not configure the setting, package dependency installation is - determined automatically - * ``True`` - User configured the setting to ``True``, package dependencies will be installed - * ``False`` - User configured the setting to ``False``, package dependencies will not be - installed - - This config option should be deprecated with the 1.0.0 release and instead an option like - ``always_install_project_deps`` should be added which overrides the default determination and - just installs the project dependencies. The counterpart (``never_install_project_deps``) - shouldn't be needed, since I don't think there's a real use case for that. - """ - if value is None: - return value - - if value.lower() == "true": - return True - if value.lower() == "false": - return False - - raise tox.exception.ConfigError( - f"install_project_deps: boolean value '{value}' needs to be 'True' or 'False'" - ) - - -@tox.hookimpl -def tox_addoption(parser: ToxParser): - """Add required configuration options to the tox INI file - - Adds the ``require_locked_deps`` configuration option to the venv to check whether all - dependencies should be treated as locked or not. - """ - +@impl +def tox_add_option(parser: ToxParser): + """Add additional command line arguments to tox to configure plugin behavior""" parser.add_argument( "--require-poetry", action="store_true", @@ -95,14 +29,6 @@ def tox_addoption(parser: ToxParser): help="(deprecated) Trigger a failure if Poetry is not available to Tox", ) - parser.add_argument( - "--parallelize-locked-install", - type=int, - dest="parallelize_locked_install", - default=None, - help="(deprecated) Number of worker threads to use for installing dependencies from the Poetry lockfile in parallel", - ) - parser.add_argument( "--parallel-install-threads", type=int, @@ -111,51 +37,50 @@ def tox_addoption(parser: ToxParser): help="Number of locked dependencies to install simultaneously; set to 0 to disable parallel installation", ) - parser.add_testenv_attribute( - name="install_dev_deps", - type="bool", - default=False, - help="(deprecated) Automatically install all Poetry development dependencies to the environment", - ) - parser.add_testenv_attribute( - name="poetry_dep_groups", - type="line-list", +@impl +def tox_add_env_config(env_conf: EnvConfigSet): + """Add required env configuration options to the tox INI file""" + env_conf.add_config( + "poetry_dep_groups", + of_type=List[str], default=[], - help="List of Poetry dependency groups to install to the environment", + desc="List of Poetry dependency groups to install to the environment", ) - parser.add_testenv_attribute( - name="install_project_deps", - type="string", - default=None, - help="Automatically install all Poetry primary dependencies to the environment", - postprocess=_postprocess_install_project_deps, + env_conf.add_config( + "install_project_deps", + of_type=bool, + default=True, + desc="Automatically install all Poetry primary dependencies to the environment", ) - parser.add_testenv_attribute( - name="require_locked_deps", - type="bool", + env_conf.add_config( + "require_locked_deps", + of_type=bool, default=False, - help="Require all dependencies in the environment be installed using the Poetry lockfile", + desc="Require all dependencies in the environment be installed using the Poetry lockfile", ) - parser.add_testenv_attribute( - name="require_poetry", - type="bool", + env_conf.add_config( + "require_poetry", + of_type=bool, default=False, - help="Trigger a failure if Poetry is not available to Tox", + desc="Trigger a failure if Poetry is not available to Tox", ) - parser.add_testenv_attribute( - name="locked_deps", - type="line-list", - help="List of locked dependencies to install to the environment using the Poetry lockfile", + env_conf.add_config( + "locked_deps", + of_type=List[str], + default=[], + desc="List of locked dependencies to install to the environment using the Poetry lockfile", ) -@tox.hookimpl -def tox_testenv_install_deps(venv: ToxVirtualEnv, action: ToxAction) -> Optional[bool]: +@impl +def tox_on_install( + tox_env: ToxVirtualEnv, section: str # pylint: disable=unused-argument +) -> None: """Install the dependencies for the current environment Loads the local Poetry environment and the corresponding lockfile then pulls the dependencies @@ -165,22 +90,21 @@ def tox_testenv_install_deps(venv: ToxVirtualEnv, action: ToxAction) -> Optional :param venv: Tox virtual environment object with configuration for the local Tox environment. :param action: Tox action object """ - try: - poetry = utilities.check_preconditions(venv, action) + poetry = utilities.check_preconditions(tox_env) except exceptions.SkipEnvironment as err: - if isinstance(err, exceptions.PoetryNotInstalledError) and ( - venv.envconfig.config.option.require_poetry or venv.envconfig.require_poetry + if ( + isinstance(err, exceptions.PoetryNotInstalledError) + and tox_env.conf["require_poetry"] ): - venv.status = err.__class__.__name__ logger.error(str(err)) - return False + raise err logger.info(str(err)) - return None + return logger.info(f"Loaded project pyproject.toml from {poetry.file}") - virtualenv = utilities.convert_virtualenv(venv) + virtualenv = utilities.convert_virtualenv(tox_env) if not poetry.locker.is_fresh(): logger.warning( @@ -188,28 +112,19 @@ def tox_testenv_install_deps(venv: ToxVirtualEnv, action: ToxAction) -> Optional ) try: - if venv.envconfig.require_locked_deps and venv.envconfig.deps: + if tox_env.conf["require_locked_deps"] and tox_env.conf["deps"].lines(): raise exceptions.LockedDepsRequiredError( - f"Unlocked dependencies '{venv.envconfig.deps}' specified for environment '{venv.name}' which requires locked dependencies" + f"Unlocked dependencies '{tox_env.conf['deps']}' specified for environment '{tox_env.name}' which requires locked dependencies" ) packages = utilities.build_package_map(poetry) - if venv.envconfig.install_dev_deps: - dev_deps = utilities.find_dev_deps(packages, virtualenv, poetry) - logger.info( - f"Identified {len(dev_deps)} development dependencies to install to env" - ) - else: - dev_deps = [] - logger.info("Env does not install development dependencies, skipping") - group_deps = utilities.dedupe_packages( list( chain( *[ utilities.find_group_deps(group, packages, virtualenv, poetry) - for group in venv.envconfig.poetry_dep_groups + for group in tox_env.conf["poetry_dep_groups"] ] ) ) @@ -219,24 +134,22 @@ def tox_testenv_install_deps(venv: ToxVirtualEnv, action: ToxAction) -> Optional ) env_deps = utilities.find_additional_deps( - packages, virtualenv, poetry, venv.envconfig.locked_deps + packages, virtualenv, poetry, tox_env.conf["locked_deps"] ) logger.info( f"Identified {len(env_deps)} environment dependencies to install to env" ) - install_project_deps = ( - venv.envconfig.install_project_deps - if venv.envconfig.install_project_deps is not None - else ( - not venv.envconfig.skip_install and not venv.envconfig.config.skipsdist - ) - ) + # extras are not set in a testenv if skip_install=true + try: + extras = tox_env.conf["extras"] + except KeyError: + extras = [] - if install_project_deps: + if tox_env.conf["install_project_deps"]: project_deps = utilities.find_project_deps( - packages, virtualenv, poetry, venv.envconfig.extras + packages, virtualenv, poetry, extras ) logger.info( f"Identified {len(project_deps)} project dependencies to install to env" @@ -245,39 +158,18 @@ def tox_testenv_install_deps(venv: ToxVirtualEnv, action: ToxAction) -> Optional project_deps = [] logger.info("Env does not install project package dependencies, skipping") except exceptions.ToxPoetryInstallerException as err: - venv.status = err.__class__.__name__ logger.error(str(err)) - return False + raise err except Exception as err: - venv.status = "InternalError" logger.error(f"Internal plugin error: {err}") raise err - dependencies = utilities.dedupe_packages( - dev_deps + group_deps + env_deps + project_deps - ) - if ( - venv.envconfig.config.option.parallel_install_threads - != constants.DEFAULT_INSTALL_THREADS - ): - parallel_threads = venv.envconfig.config.option.parallel_install_threads - else: - parallel_threads = ( - venv.envconfig.config.option.parallelize_locked_install - if venv.envconfig.config.option.parallelize_locked_install is not None - else constants.DEFAULT_INSTALL_THREADS - ) - log_parallel = f" (using {parallel_threads} threads)" if parallel_threads else "" + dependencies = utilities.dedupe_packages(group_deps + env_deps + project_deps) - action.setactivity( - __about__.__title__, - f"Installing {len(dependencies)} dependencies from Poetry lock file{log_parallel}", - ) + logger.info(f"Installing {len(dependencies)} dependencies from Poetry lock file") installer.install( poetry, - venv, + tox_env, dependencies, - parallel_threads, + tox_env.options.parallel_install_threads, ) - - return venv.envconfig.require_locked_deps or None diff --git a/tox_poetry_installer/installer.py b/tox_poetry_installer/installer.py index a0d1085..60d3a7b 100644 --- a/tox_poetry_installer/installer.py +++ b/tox_poetry_installer/installer.py @@ -9,8 +9,7 @@ from datetime import datetime from typing import Collection from typing import Set -from poetry.core.packages.package import Package as PoetryPackage -from tox.venv import VirtualEnv as ToxVirtualEnv +from tox.tox_env.api import ToxEnv as ToxVirtualEnv from tox_poetry_installer import logger from tox_poetry_installer import utilities @@ -22,7 +21,7 @@ if typing.TYPE_CHECKING: def install( poetry: "_poetry.Poetry", venv: ToxVirtualEnv, - packages: Collection[PoetryPackage], + packages: Collection["_poetry.PoetryPackage"], parallels: int = 0, ): """Install a bunch of packages to a virtualenv @@ -35,22 +34,21 @@ def install( """ from tox_poetry_installer import _poetry - logger.info( - f"Installing {len(packages)} packages to environment at {venv.envconfig.envdir}" - ) + logger.info(f"Installing {len(packages)} packages to environment at {venv.env_dir}") - pip = _poetry.PipInstaller( + install_executor = _poetry.Executor( env=utilities.convert_virtualenv(venv), io=_poetry.NullIO(), pool=poetry.pool, + config=_poetry.Config(), ) - installed: Set[PoetryPackage] = set() + installed: Set[_poetry.PoetryPackage] = set() - def logged_install(dependency: PoetryPackage) -> None: + def logged_install(dependency: _poetry.PoetryPackage) -> None: start = datetime.now() logger.debug(f"Installing {dependency}") - pip.install(dependency) + install_executor.execute([_poetry.Install(package=dependency)]) end = datetime.now() logger.debug(f"Finished installing {dependency} in {end - start}") diff --git a/tox_poetry_installer/logger.py b/tox_poetry_installer/logger.py index 11bee82..1833307 100644 --- a/tox_poetry_installer/logger.py +++ b/tox_poetry_installer/logger.py @@ -4,26 +4,26 @@ Calling ``tox.reporter.something()`` and having to format a string with the pref gets really old fast, but more importantly it also makes the flow of the main code more difficult to follow because of the added complexity. """ -import tox +import logging from tox_poetry_installer import constants def error(message: str): - """Wrapper around :func:`tox.reporter.error`""" - tox.reporter.error(f"{constants.REPORTER_PREFIX} {message}") + """Wrapper around :func:`logging.error` that prefixes the reporter prefix onto the message""" + logging.error(f"{constants.REPORTER_PREFIX} {message}") def warning(message: str): - """Wrapper around :func:`tox.reporter.warning`""" - tox.reporter.warning(f"{constants.REPORTER_PREFIX} {message}") + """Wrapper around :func:`logging.warning`""" + logging.warning(f"{constants.REPORTER_PREFIX} {message}") def info(message: str): - """Wrapper around :func:`tox.reporter.verbosity1`""" - tox.reporter.verbosity1(f"{constants.REPORTER_PREFIX} {message}") + """Wrapper around :func:`logging.info`""" + logging.info(f"{constants.REPORTER_PREFIX} {message}") def debug(message: str): - """Wrapper around :func:`tox.reporter.verbosity2`""" - tox.reporter.verbosity2(f"{constants.REPORTER_PREFIX} {message}") + """Wrapper around :func:`logging.debug`""" + logging.debug(f"{constants.REPORTER_PREFIX} {message}") diff --git a/tox_poetry_installer/utilities.py b/tox_poetry_installer/utilities.py index 000cd14..dce3656 100644 --- a/tox_poetry_installer/utilities.py +++ b/tox_poetry_installer/utilities.py @@ -12,8 +12,8 @@ from typing import Set from poetry.core.packages.dependency import Dependency as PoetryDependency from poetry.core.packages.package import Package as PoetryPackage -from tox.action import Action as ToxAction -from tox.venv import VirtualEnv as ToxVirtualEnv +from tox.tox_env.api import ToxEnv as ToxVirtualEnv +from tox.tox_env.package import PackageToxEnv from tox_poetry_installer import constants from tox_poetry_installer import exceptions @@ -26,50 +26,28 @@ if typing.TYPE_CHECKING: PackageMap = Dict[str, List[PoetryPackage]] -def check_preconditions(venv: ToxVirtualEnv, action: ToxAction) -> "_poetry.Poetry": +def check_preconditions(venv: ToxVirtualEnv) -> "_poetry.Poetry": """Check that the local project environment meets expectations""" + # Skip running the plugin for the provisioning environment. The provisioned environment, # for alternative Tox versions and/or the ``requires`` meta dependencies is specially # handled by Tox and is out of scope for this plugin. Since one of the ways to install this # plugin in the first place is via the Tox provisioning environment, it quickly becomes a # chicken-and-egg problem. - if action.name == venv.envconfig.config.provision_tox_env: - raise exceptions.SkipEnvironment( - f"Skipping Tox provisioning env '{action.name}'" - ) + if isinstance(venv, PackageToxEnv): + raise exceptions.SkipEnvironment(f"Skipping Tox provisioning env '{venv.name}'") - # Skip running the plugin for the packaging environment. PEP-517 front ends can handle - # that better than we can, so let them do their thing. More to the point: if you're having - # problems in the packaging env that this plugin would solve, god help you. - if action.name == venv.envconfig.config.isolated_build_env: - raise exceptions.SkipEnvironment( - f"Skipping isolated packaging build env '{action.name}'" - ) - - if venv.envconfig.config.option.require_poetry: + if venv.options.require_poetry: logger.warning( "DEPRECATION: The '--require-poetry' runtime option is deprecated and will be " "removed in version 1.0.0. Please update test environments that require Poetry to " "set the 'require_poetry = true' option in tox.ini" ) - if venv.envconfig.config.option.parallelize_locked_install is not None: - logger.warning( - "DEPRECATION: The '--parallelize-locked-install' option is deprecated and will " - "be removed in version 1.0.0. Please use the '--parallel-install-threads' option." - ) - - if venv.envconfig.install_dev_deps: - logger.warning( - "DEPRECATION: The 'install_dev_deps' option is deprecated and will be removed in " - "version 1.0.0. Please update test environments that install development dependencies " - "to set the 'poetry_dev_groups = [dev]' option in tox.ini" - ) - from tox_poetry_installer import _poetry try: - return _poetry.Factory().create_poetry(venv.envconfig.config.toxinidir) + return _poetry.Factory().create_poetry(venv.core["tox_root"]) # Support running the plugin when the current tox project does not use Poetry for its # environment/dependency management. # @@ -89,7 +67,7 @@ def convert_virtualenv(venv: ToxVirtualEnv) -> "_poetry.VirtualEnv": """ from tox_poetry_installer import _poetry - return _poetry.VirtualEnv(path=Path(venv.envconfig.envdir)) + return _poetry.VirtualEnv(path=Path(venv.env_dir)) def build_package_map(poetry: "_poetry.Poetry") -> PackageMap: