Fabian Affolter 2024-10-26 09:04:51 +02:00
parent ea67f6769e
commit e640433702

View File

@ -14,24 +14,24 @@
pythonOlder,
pyyaml,
scipy,
six,
setuptools,
}:
buildPythonPackage rec {
pname = "dependency-injector";
version = "4.41.0";
format = "setuptools";
version = "4.42.0";
pyproject = true;
disabled = pythonOlder "3.7";
src = fetchFromGitHub {
owner = "ets-labs";
repo = "python-dependency-injector";
rev = version;
hash = "sha256-U3U/L8UuYrfpm4KwVNmViTbam7QdZd2vp1p+ENtOJlw=";
rev = "refs/tags/${version}";
hash = "sha256-ryPNmiIKQzR4WSjt7hi4C+iTsYvfj5TYGy+9PJxX+10=";
};
propagatedBuildInputs = [ six ];
build-system = [ setuptools ];
optional-dependencies = {
aiohttp = [ aiohttp ];
@ -40,20 +40,15 @@ buildPythonPackage rec {
yaml = [ pyyaml ];
};
nativeCheckInputs =
[
fastapi
httpx
mypy-boto3-s3
numpy
pytest-asyncio
pytestCheckHook
scipy
]
++ optional-dependencies.aiohttp
++ optional-dependencies.pydantic
++ optional-dependencies.yaml
++ optional-dependencies.flask;
nativeCheckInputs = [
fastapi
httpx
mypy-boto3-s3
numpy
pytest-asyncio
pytestCheckHook
scipy
] ++ lib.flatten (builtins.attrValues optional-dependencies);
pythonImportsCheck = [ "dependency_injector" ];
@ -61,6 +56,8 @@ buildPythonPackage rec {
# Exclude tests for EOL Python releases
"tests/unit/ext/test_aiohttp_py35.py"
"tests/unit/wiring/test_*_py36.py"
"tests/unit/providers/configuration/test_from_pydantic_py36.py"
"tests/unit/providers/configuration/test_pydantic_settings_in_init_py36.py"
];
meta = with lib; {