2024-06-20 14:57:18 +00:00
|
|
|
{
|
|
|
|
bitarray,
|
|
|
|
buildPythonPackage,
|
|
|
|
dill,
|
|
|
|
diskcache,
|
|
|
|
fetchFromGitHub,
|
|
|
|
hiredis,
|
|
|
|
hypothesis,
|
|
|
|
lib,
|
|
|
|
pytest,
|
|
|
|
pytest-asyncio,
|
2024-09-19 14:19:46 +00:00
|
|
|
pytest-cov-stub,
|
2024-06-20 14:57:18 +00:00
|
|
|
pytest-rerunfailures,
|
|
|
|
pytestCheckHook,
|
|
|
|
redis,
|
|
|
|
setuptools,
|
|
|
|
xxhash,
|
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "cashews";
|
2024-09-19 14:19:46 +00:00
|
|
|
version = "7.2.0";
|
2024-06-20 14:57:18 +00:00
|
|
|
pyproject = true;
|
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "Krukov";
|
|
|
|
repo = "cashews";
|
|
|
|
rev = "refs/tags/${version}";
|
2024-09-19 14:19:46 +00:00
|
|
|
hash = "sha256-7T9M8ioeTjW7OmcHyxZ6awNfp9kVU8Hi+Lgy17jXxK4=";
|
2024-06-20 14:57:18 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
build-system = [ setuptools ];
|
|
|
|
|
2024-10-04 16:56:33 +00:00
|
|
|
optional-dependencies = {
|
2024-06-20 14:57:18 +00:00
|
|
|
dill = [ dill ];
|
|
|
|
diskcache = [ diskcache ];
|
|
|
|
redis = [ redis ];
|
|
|
|
speedup = [
|
|
|
|
bitarray
|
|
|
|
hiredis
|
|
|
|
xxhash
|
|
|
|
];
|
|
|
|
};
|
|
|
|
|
|
|
|
nativeCheckInputs = [
|
|
|
|
hypothesis
|
|
|
|
pytest
|
|
|
|
pytest-asyncio
|
2024-09-19 14:19:46 +00:00
|
|
|
pytest-cov-stub
|
2024-06-20 14:57:18 +00:00
|
|
|
pytest-rerunfailures
|
|
|
|
pytestCheckHook
|
|
|
|
];
|
|
|
|
|
|
|
|
disabledTests = [
|
|
|
|
# these tests require too many dependencies
|
|
|
|
"redis"
|
|
|
|
"diskcache"
|
|
|
|
"integration"
|
|
|
|
];
|
|
|
|
|
|
|
|
pythonImportsCheck = [ "cashews" ];
|
|
|
|
|
|
|
|
meta = {
|
|
|
|
description = "Cache tools with async power";
|
|
|
|
homepage = "https://github.com/Krukov/cashews/";
|
|
|
|
changelog = "https://github.com/Krukov/cashews/releases/tag/${version}";
|
|
|
|
license = lib.licenses.mit;
|
|
|
|
maintainers = with lib.maintainers; [ moraxyc ];
|
|
|
|
};
|
|
|
|
}
|