b62eea41c7
nixpkgs bumped pandas to 3.0.4, which trips df-diskcache's pinned 'pandas<3,>=1' runtime dependency check. Upstream still pins pandas<3 as of the v0.1.0 tag (no indication of pandas 3 testing), but the package's own test suite (4/4) passes fine against pandas 3.0.4 here. This was breaking the sbomnix build, which depends on dfdiskcache. https://github.com/thombashi/df-diskcache/blob/v0.1.0/requirements/requirements.txt
53 lines
1.2 KiB
Nix
53 lines
1.2 KiB
Nix
{
|
|
lib,
|
|
buildPythonPackage,
|
|
fetchFromGitHub,
|
|
pandas,
|
|
setuptools,
|
|
simplesqlite,
|
|
typing-extensions,
|
|
pytestCheckHook,
|
|
}:
|
|
|
|
buildPythonPackage rec {
|
|
pname = "df-diskcache";
|
|
version = "0.0.2";
|
|
pyproject = true;
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "thombashi";
|
|
repo = "df-diskcache";
|
|
rev = "v${version}";
|
|
hash = "sha256-s+sqEPXw6tbEz9mnG+qeUSF6BmDssYhaDYOmraFaRbw=";
|
|
};
|
|
|
|
nativeBuildInputs = [ setuptools ];
|
|
|
|
# Upstream pins pandas<3 (still true as of the v0.1.0 tag), but the
|
|
# package works fine against pandas 3.x; relax the constraint rather
|
|
# than staying behind on pandas.
|
|
# https://github.com/thombashi/df-diskcache/blob/v0.1.0/requirements/requirements.txt
|
|
pythonRelaxDeps = [ "pandas" ];
|
|
|
|
propagatedBuildInputs = [
|
|
pandas
|
|
simplesqlite
|
|
typing-extensions
|
|
];
|
|
|
|
preCheck = ''
|
|
# Needed for Permission denied: '/homeless-shelter'
|
|
export HOME=$(mktemp -d)
|
|
'';
|
|
|
|
nativeCheckInputs = [ pytestCheckHook ];
|
|
pythonImportsCheck = [ "dfdiskcache" ];
|
|
|
|
meta = {
|
|
description = "Python library for caching pandas.DataFrame objects to local disk";
|
|
homepage = "https://github.com/thombashi/df-diskcache";
|
|
license = lib.licenses.mit;
|
|
maintainers = with lib.maintainers; [ henrirosten ];
|
|
};
|
|
}
|