diff options
author | Martin Weinelt <hexa@darmstadt.ccc.de> | 2022-05-22 16:26:11 +0200 |
---|---|---|
committer | Martin Weinelt <hexa@darmstadt.ccc.de> | 2022-05-22 16:31:53 +0200 |
commit | 272430c82399d0a2f22b51dd0e564a8709ba6782 (patch) | |
tree | 4bc42f8b3229f50b0e2305e0c0895edb63314fb0 /pkgs/development/python-modules | |
parent | 809ffd6cd33b0020c6ac0be57bf25f3da4c17d31 (diff) |
treewide: migrate python packages to optional-dependencies
This follows the term used by PEP 621.
Diffstat (limited to 'pkgs/development/python-modules')
35 files changed, 73 insertions, 73 deletions
diff --git a/pkgs/development/python-modules/Mako/default.nix b/pkgs/development/python-modules/Mako/default.nix index 5eca80d98a51..a74f9988ad7a 100644 --- a/pkgs/development/python-modules/Mako/default.nix +++ b/pkgs/development/python-modules/Mako/default.nix @@ -30,7 +30,7 @@ buildPythonPackage rec { markupsafe ]; - passthru.extras-require = { + passthru.optional-dependencies = { babel = [ babel ]; @@ -39,7 +39,7 @@ buildPythonPackage rec { checkInputs = [ pytestCheckHook mock - ] ++ passthru.extras-require.babel; + ] ++ passthru.optional-dependencies.babel; disabledTests = lib.optionals isPyPy [ # https://github.com/sqlalchemy/mako/issues/315 diff --git a/pkgs/development/python-modules/adb-shell/default.nix b/pkgs/development/python-modules/adb-shell/default.nix index 792729da1fac..bc10948f070f 100644 --- a/pkgs/development/python-modules/adb-shell/default.nix +++ b/pkgs/development/python-modules/adb-shell/default.nix @@ -33,7 +33,7 @@ buildPythonPackage rec { rsa ]; - passthru.extras-require = { + passthru.optional-dependencies = { async = [ aiofiles ]; @@ -47,8 +47,8 @@ buildPythonPackage rec { pycryptodome pytestCheckHook ] - ++ passthru.extras-require.async - ++ passthru.extras-require.usb; + ++ passthru.optional-dependencies.async + ++ passthru.optional-dependencies.usb; disabledTests = lib.optionals (pythonAtLeast "3.10") [ # Tests are failing with Python 3.10 diff --git a/pkgs/development/python-modules/androidtv/default.nix b/pkgs/development/python-modules/androidtv/default.nix index 2f7afc113756..456186e45ab3 100644 --- a/pkgs/development/python-modules/androidtv/default.nix +++ b/pkgs/development/python-modules/androidtv/default.nix @@ -28,19 +28,19 @@ buildPythonPackage rec { pure-python-adb ]; - passthru.extras-require = { + passthru.optional-dependencies = { async = [ aiofiles ]; - inherit (adb-shell.extras-require) usb; + inherit (adb-shell.optional-dependencies) usb; }; checkInputs = [ mock pytestCheckHook ] - ++ passthru.extras-require.async - ++ passthru.extras-require.usb; + ++ passthru.optional-dependencies.async + ++ passthru.optional-dependencies.usb; disabledTests = [ # Requires git but fails anyway diff --git a/pkgs/development/python-modules/autobahn/default.nix b/pkgs/development/python-modules/autobahn/default.nix index ff866c6364ca..5fd6f1a3b8f9 100644 --- a/pkgs/development/python-modules/autobahn/default.nix +++ b/pkgs/development/python-modules/autobahn/default.nix @@ -68,8 +68,8 @@ buildPythonPackage rec { mock pytest-asyncio pytestCheckHook - ] ++ passthru.extras-require.scram - ++ passthru.extras-require.serialization; + ] ++ passthru.optional-dependencies.scram + ++ passthru.optional-dependencies.serialization; postPatch = '' substituteInPlace setup.py \ @@ -89,7 +89,7 @@ buildPythonPackage rec { "autobahn" ]; - passthru.extras-require = rec { + passthru.optional-dependencies = rec { all = accelerate ++ compress ++ encryption ++ nvx ++ serialization ++ scram ++ twisted ++ ui ++ xbr; accelerate = [ /* wsaccel */ ]; compress = [ python-snappy ]; diff --git a/pkgs/development/python-modules/buildbot/default.nix b/pkgs/development/python-modules/buildbot/default.nix index 611177212271..f08c43440625 100644 --- a/pkgs/development/python-modules/buildbot/default.nix +++ b/pkgs/development/python-modules/buildbot/default.nix @@ -54,7 +54,7 @@ let pyyaml ] # tls - ++ twisted.extras-require.tls; + ++ twisted.optional-dependencies.tls; checkInputs = [ treq diff --git a/pkgs/development/python-modules/clize/default.nix b/pkgs/development/python-modules/clize/default.nix index 10b4c8f68c69..1b0caeaaf266 100644 --- a/pkgs/development/python-modules/clize/default.nix +++ b/pkgs/development/python-modules/clize/default.nix @@ -40,7 +40,7 @@ buildPythonPackage rec { six ]; - passthru.extras-require = { + passthru.optional-dependencies = { datetime = [ python-dateutil ]; diff --git a/pkgs/development/python-modules/dask/default.nix b/pkgs/development/python-modules/dask/default.nix index 79f07c6e88f2..59869efbffd8 100644 --- a/pkgs/development/python-modules/dask/default.nix +++ b/pkgs/development/python-modules/dask/default.nix @@ -98,7 +98,7 @@ buildPythonPackage rec { "dask.diagnostics" ]; - passthru.extras-require = { + passthru.optional-dependencies = { complete = [ distributed ]; }; diff --git a/pkgs/development/python-modules/datashader/default.nix b/pkgs/development/python-modules/datashader/default.nix index b9630aa07fd4..243571f248bb 100644 --- a/pkgs/development/python-modules/datashader/default.nix +++ b/pkgs/development/python-modules/datashader/default.nix @@ -46,7 +46,7 @@ buildPythonPackage rec { param pyct scipy - ] ++ dask.extras-require.complete; + ] ++ dask.optional-dependencies.complete; checkInputs = [ pytestCheckHook diff --git a/pkgs/development/python-modules/django_modelcluster/default.nix b/pkgs/development/python-modules/django_modelcluster/default.nix index 02995c1570b9..d59682de2f81 100644 --- a/pkgs/development/python-modules/django_modelcluster/default.nix +++ b/pkgs/development/python-modules/django_modelcluster/default.nix @@ -27,11 +27,11 @@ buildPythonPackage rec { pytz ]; - passthru.extras-require.taggit = [ + passthru.optional-dependencies.taggit = [ django-taggit ]; - checkInputs = passthru.extras-require.taggit; + checkInputs = passthru.optional-dependencies.taggit; checkPhase = '' runHook preCheck diff --git a/pkgs/development/python-modules/fastapi/default.nix b/pkgs/development/python-modules/fastapi/default.nix index 63071fd9e446..3d418d75333f 100644 --- a/pkgs/development/python-modules/fastapi/default.nix +++ b/pkgs/development/python-modules/fastapi/default.nix @@ -49,7 +49,7 @@ buildPythonPackage rec { pytest-asyncio sqlalchemy trio - ] ++ passlib.extras-require.bcrypt; + ] ++ passlib.optional-dependencies.bcrypt; patches = [ # Bump starlette, https://github.com/tiangolo/fastapi/pull/4483 diff --git a/pkgs/development/python-modules/flask-security-too/default.nix b/pkgs/development/python-modules/flask-security-too/default.nix index 789060ed2b5e..eb9c01699e5b 100644 --- a/pkgs/development/python-modules/flask-security-too/default.nix +++ b/pkgs/development/python-modules/flask-security-too/default.nix @@ -63,7 +63,7 @@ buildPythonPackage rec { passlib ]; - passthru.extras-require = { + passthru.optional-dependencies = { babel = [ babel flask-babel @@ -95,10 +95,10 @@ buildPythonPackage rec { pytestCheckHook zxcvbn ] - ++ passthru.extras-require.babel - ++ passthru.extras-require.common - ++ passthru.extras-require.fsqla - ++ passthru.extras-require.mfa; + ++ passthru.optional-dependencies.babel + ++ passthru.optional-dependencies.common + ++ passthru.optional-dependencies.fsqla + ++ passthru.optional-dependencies.mfa; pythonImportsCheck = [ "flask_security" ]; diff --git a/pkgs/development/python-modules/httpcore/default.nix b/pkgs/development/python-modules/httpcore/default.nix index 5b8d84ec3089..d2286b6b022b 100644 --- a/pkgs/development/python-modules/httpcore/default.nix +++ b/pkgs/development/python-modules/httpcore/default.nix @@ -42,7 +42,7 @@ buildPythonPackage rec { sniffio ]; - passthru.extras-require = { + passthru.optional-dependencies = { http2 = [ h2 ]; socks = [ socksio ]; }; @@ -56,8 +56,8 @@ buildPythonPackage rec { trio trustme uvicorn - ] ++ passthru.extras-require.http2 - ++ passthru.extras-require.socks; + ] ++ passthru.optional-dependencies.http2 + ++ passthru.optional-dependencies.socks; pythonImportsCheck = [ "httpcore" ]; diff --git a/pkgs/development/python-modules/httpx-socks/default.nix b/pkgs/development/python-modules/httpx-socks/default.nix index 3bfbf2327f21..f8334593904c 100644 --- a/pkgs/development/python-modules/httpx-socks/default.nix +++ b/pkgs/development/python-modules/httpx-socks/default.nix @@ -38,7 +38,7 @@ buildPythonPackage rec { python-socks ]; - passthru.extras-require = { + passthru.optional-dependencies = { asyncio = [ async-timeout ]; trio = [ trio ]; }; diff --git a/pkgs/development/python-modules/httpx/default.nix b/pkgs/development/python-modules/httpx/default.nix index d75dbaa1c9bd..0070d5d04eff 100644 --- a/pkgs/development/python-modules/httpx/default.nix +++ b/pkgs/development/python-modules/httpx/default.nix @@ -49,7 +49,7 @@ buildPythonPackage rec { async_generator ]; - passthru.extras-require = { + passthru.optional-dependencies = { http2 = [ h2 ]; socks = [ socksio ]; brotli = if isPyPy then [ brotlicffi ] else [ brotli ]; @@ -63,9 +63,9 @@ buildPythonPackage rec { trustme typing-extensions uvicorn - ] ++ passthru.extras-require.http2 - ++ passthru.extras-require.brotli - ++ passthru.extras-require.socks; + ] ++ passthru.optional-dependencies.http2 + ++ passthru.optional-dependencies.brotli + ++ passthru.optional-dependencies.socks; postPatch = '' substituteInPlace setup.py \ diff --git a/pkgs/development/python-modules/ibis-framework/default.nix b/pkgs/development/python-modules/ibis-framework/default.nix index c5dfcc13e5c4..539238ba948d 100644 --- a/pkgs/development/python-modules/ibis-framework/default.nix +++ b/pkgs/development/python-modules/ibis-framework/default.nix @@ -99,7 +99,7 @@ buildPythonPackage rec { pytest-mock pytest-randomly pytest-xdist - ] ++ lib.concatMap (name: passthru.extras-require.${name}) testBackends; + ] ++ lib.concatMap (name: passthru.optional-dependencies.${name}) testBackends; preBuild = '' # setup.py exists only for developer convenience and is automatically generated @@ -139,7 +139,7 @@ buildPythonPackage rec { ] ++ map (backend: "ibis.backends.${backend}") testBackends; passthru = { - extras-require = { + optional-dependencies = { clickhouse = [ clickhouse-cityhash clickhouse-driver lz4 ]; dask = [ dask pyarrow ]; datafusion = [ datafusion ]; diff --git a/pkgs/development/python-modules/ldaptor/default.nix b/pkgs/development/python-modules/ldaptor/default.nix index 55725fb49c9f..f7b5e7cf96b8 100644 --- a/pkgs/development/python-modules/ldaptor/default.nix +++ b/pkgs/development/python-modules/ldaptor/default.nix @@ -27,7 +27,7 @@ buildPythonPackage rec { six twisted zope_interface - ] ++ twisted.extras-require.tls; + ] ++ twisted.optional-dependencies.tls; checkInputs = [ twisted diff --git a/pkgs/development/python-modules/magic-wormhole-mailbox-server/default.nix b/pkgs/development/python-modules/magic-wormhole-mailbox-server/default.nix index 77870ed68365..4d000c7a1672 100644 --- a/pkgs/development/python-modules/magic-wormhole-mailbox-server/default.nix +++ b/pkgs/development/python-modules/magic-wormhole-mailbox-server/default.nix @@ -25,8 +25,8 @@ buildPythonPackage rec { six twisted autobahn - ] ++ autobahn.extras-require.twisted - ++ twisted.extras-require.tls; + ] ++ autobahn.optional-dependencies.twisted + ++ twisted.optional-dependencies.tls; checkInputs = [ treq diff --git a/pkgs/development/python-modules/magic-wormhole/default.nix b/pkgs/development/python-modules/magic-wormhole/default.nix index c6450c3cecb9..38e0b16726a8 100644 --- a/pkgs/development/python-modules/magic-wormhole/default.nix +++ b/pkgs/development/python-modules/magic-wormhole/default.nix @@ -42,8 +42,8 @@ buildPythonPackage rec { click humanize txtorcon - ] ++ autobahn.extras-require.twisted - ++ twisted.extras-require.tls; + ] ++ autobahn.optional-dependencies.twisted + ++ twisted.optional-dependencies.tls; checkInputs = [ mock diff --git a/pkgs/development/python-modules/passlib/default.nix b/pkgs/development/python-modules/passlib/default.nix index 8fd7b177a27c..3a39f7ac7d58 100644 --- a/pkgs/development/python-modules/passlib/default.nix +++ b/pkgs/development/python-modules/passlib/default.nix @@ -16,7 +16,7 @@ buildPythonPackage rec { sha256 = "defd50f72b65c5402ab2c573830a6978e5f202ad0d984793c8dde2c4152ebe04"; }; - passthru.extras-require = { + passthru.optional-dependencies = { argon2 = [ argon2-cffi ]; bcrypt = [ bcrypt ]; totp = [ cryptography ]; @@ -24,9 +24,9 @@ buildPythonPackage rec { checkInputs = [ pytestCheckHook - ] ++ passthru.extras-require.argon2 - ++ passthru.extras-require.bcrypt - ++ passthru.extras-require.totp; + ] ++ passthru.optional-dependencies.argon2 + ++ passthru.optional-dependencies.bcrypt + ++ passthru.optional-dependencies.totp; meta = with lib; { description = "A password hashing library for Python"; diff --git a/pkgs/development/python-modules/pure-python-adb/default.nix b/pkgs/development/python-modules/pure-python-adb/default.nix index cb054feaf10f..512c38b730d3 100644 --- a/pkgs/development/python-modules/pure-python-adb/default.nix +++ b/pkgs/development/python-modules/pure-python-adb/default.nix @@ -17,7 +17,7 @@ buildPythonPackage rec { sha256 = "0kdr7w2fhgjpcf1k3l6an9im583iqkr6v8hb4q1zw30nh3bqkk0f"; }; - passthru.extras-require = { + passthru.optional-dependencies = { async = [ aiofiles ]; @@ -28,7 +28,7 @@ buildPythonPackage rec { checkInputs = [ pytestCheckHook ] - ++ passthru.extras-require.async; + ++ passthru.optional-dependencies.async; pythonImportsCheck = [ "ppadb.client" diff --git a/pkgs/development/python-modules/pygatt/default.nix b/pkgs/development/python-modules/pygatt/default.nix index 8d6f67a4c751..fab5c093c502 100644 --- a/pkgs/development/python-modules/pygatt/default.nix +++ b/pkgs/development/python-modules/pygatt/default.nix @@ -25,7 +25,7 @@ buildPythonPackage rec { pyserial ]; - passthru.extras-require.GATTTOOL = [ + passthru.optional-dependencies.GATTTOOL = [ pexpect ]; @@ -34,7 +34,7 @@ buildPythonPackage rec { nose pytestCheckHook ] - ++ passthru.extras-require.GATTTOOL; + ++ passthru.optional-dependencies.GATTTOOL; postPatch = '' # Not support for Python < 3.4 diff --git a/pkgs/development/python-modules/python-barcode/default.nix b/pkgs/development/python-modules/python-barcode/default.nix index 165cb5cc5d27..5d64f933b691 100644 --- a/pkgs/development/python-modules/python-barcode/default.nix +++ b/pkgs/development/python-modules/python-barcode/default.nix @@ -23,7 +23,7 @@ buildPythonPackage rec { setuptools-scm ]; - passthru.extras-require = { + passthru.optional-dependencies = { images = [ pillow ]; @@ -38,7 +38,7 @@ buildPythonPackage rec { checkInputs = [ pytestCheckHook - ] ++ passthru.extras-require.images; + ] ++ passthru.optional-dependencies.images; pythonImportsCheck = [ "barcode" ]; diff --git a/pkgs/development/python-modules/pytradfri/default.nix b/pkgs/development/python-modules/pytradfri/default.nix index 70f9acd0380f..1f523b60eaa0 100644 --- a/pkgs/development/python-modules/pytradfri/default.nix +++ b/pkgs/development/python-modules/pytradfri/default.nix @@ -21,7 +21,7 @@ buildPythonPackage rec { hash = "sha256-12ol+2CnoPfkxmDGJJAkoafHGpQuWC4lh0N7lSvx2DE="; }; - passthru.extras-require = { + passthru.optional-dependencies = { async = [ aiocoap dtlssocket @@ -31,7 +31,7 @@ buildPythonPackage rec { checkInputs = [ pytestCheckHook ] - ++ passthru.extras-require.async; + ++ passthru.optional-dependencies.async; pythonImportsCheck = [ "pytradfri" diff --git a/pkgs/development/python-modules/rdflib/default.nix b/pkgs/development/python-modules/rdflib/default.nix index 1aa998911343..1aa995d85d77 100644 --- a/pkgs/development/python-modules/rdflib/default.nix +++ b/pkgs/development/python-modules/rdflib/default.nix @@ -43,7 +43,7 @@ buildPythonPackage rec { importlib-metadata ]; - passthru.extras-require = { + passthru.optional-dependencies = { html = [ html5lib ]; @@ -55,8 +55,8 @@ buildPythonPackage rec { checkInputs = [ pytestCheckHook ] - ++ passthru.extras-require.networkx - ++ passthru.extras-require.html; + ++ passthru.optional-dependencies.networkx + ++ passthru.optional-dependencies.html; pytestFlagsArray = [ # requires network access diff --git a/pkgs/development/python-modules/redis/default.nix b/pkgs/development/python-modules/redis/default.nix index b38975c9c6d6..2018006caa9b 100644 --- a/pkgs/development/python-modules/redis/default.nix +++ b/pkgs/development/python-modules/redis/default.nix @@ -40,7 +40,7 @@ buildPythonPackage rec { importlib-metadata ]; - passthru.extras-require = { + passthru.optional-dependencies = { hidredis = [ hiredis ]; diff --git a/pkgs/development/python-modules/relatorio/default.nix b/pkgs/development/python-modules/relatorio/default.nix index 86e53cde95d5..1baf6f4b0aac 100644 --- a/pkgs/development/python-modules/relatorio/default.nix +++ b/pkgs/development/python-modules/relatorio/default.nix @@ -27,14 +27,14 @@ buildPythonPackage rec { lxml ]; - passthru.extras-require = { + passthru.optional-dependencies = { chart = [ /* pycha */ pyyaml ]; fodt = [ python-magic ]; }; checkInputs = [ pytestCheckHook - ] ++ passthru.extras-require.fodt; + ] ++ passthru.optional-dependencies.fodt; pythonImportsCheck = [ "relatorio" ]; diff --git a/pkgs/development/python-modules/requests-aws4auth/default.nix b/pkgs/development/python-modules/requests-aws4auth/default.nix index c38309f6d8d9..e024efb58b0f 100644 --- a/pkgs/development/python-modules/requests-aws4auth/default.nix +++ b/pkgs/development/python-modules/requests-aws4auth/default.nix @@ -28,13 +28,13 @@ buildPythonPackage rec { six ]; - passthru.extras-require = { + passthru.optional-dependencies = { httpx = [ httpx ]; }; checkInputs = [ pytestCheckHook - ] ++ passthru.extras-require.httpx; + ] ++ passthru.optional-dependencies.httpx; pythonImportsCheck = [ "requests_aws4auth" diff --git a/pkgs/development/python-modules/samsungctl/default.nix b/pkgs/development/python-modules/samsungctl/default.nix index f917c265973a..92af8775d81d 100644 --- a/pkgs/development/python-modules/samsungctl/default.nix +++ b/pkgs/development/python-modules/samsungctl/default.nix @@ -15,7 +15,7 @@ buildPythonPackage rec { sha256 = "0ipz3fd65rqkxlb02sql0awc3vnslrwb2pfrsnpfnf8bfgxpbh9g"; }; - passthru.extras-require = { + passthru.optional-dependencies = { websocket = [ websocket-client ]; diff --git a/pkgs/development/python-modules/samsungtvws/default.nix b/pkgs/development/python-modules/samsungtvws/default.nix index 383841caffa4..2e97bae92b6a 100644 --- a/pkgs/development/python-modules/samsungtvws/default.nix +++ b/pkgs/development/python-modules/samsungtvws/default.nix @@ -39,7 +39,7 @@ buildPythonPackage rec { websocket-client ]; - passthru.extras-require = { + passthru.optional-dependencies = { async = [ aiohttp websockets @@ -55,8 +55,8 @@ buildPythonPackage rec { pytest-asyncio pytestCheckHook ] - ++ passthru.extras-require.async - ++ passthru.extras-require.encrypted; + ++ passthru.optional-dependencies.async + ++ passthru.optional-dependencies.encrypted; pythonImportsCheck = [ "samsungtvws" ]; diff --git a/pkgs/development/python-modules/treq/default.nix b/pkgs/development/python-modules/treq/default.nix index 1902a578ec2b..0f77463077a0 100644 --- a/pkgs/development/python-modules/treq/default.nix +++ b/pkgs/development/python-modules/treq/default.nix @@ -20,7 +20,7 @@ buildPythonPackage rec { requests incremental twisted - ] ++ twisted.extras-require.tls; + ] ++ twisted.optional-dependencies.tls; checkInputs = [ httpbin diff --git a/pkgs/development/python-modules/trytond/default.nix b/pkgs/development/python-modules/trytond/default.nix index 431342cf02d5..7a1ae2af2cc3 100644 --- a/pkgs/development/python-modules/trytond/default.nix +++ b/pkgs/development/python-modules/trytond/default.nix @@ -53,9 +53,9 @@ buildPythonPackage rec { weasyprint gevent pillow - ] ++ relatorio.extras-require.fodt - ++ passlib.extras-require.bcrypt - ++ passlib.extras-require.argon2 + ] ++ relatorio.optional-dependencies.fodt + ++ passlib.optional-dependencies.bcrypt + ++ passlib.optional-dependencies.argon2 ++ lib.o |