nixpkgs/pkgs/development/python-modules/python-louvain/default.nix
Ihar Hrachyshka 567e8dfd8e
treewide: clean up 'meta = with' pattern
This commit was created by a combination of scripts and tools:
- an ast-grep script to prefix things in meta with `lib.`,
- a modified nixf-diagnose / nixf combination to remove unused `with
lib;`, and
- regular nixfmt.

Co-authored-by: Wolfgang Walther <walther@technowledgy.de>
2025-12-10 18:09:49 +01:00

50 lines
989 B
Nix

{
lib,
fetchPypi,
buildPythonPackage,
fetchpatch,
networkx,
pandas,
scipy,
numpy,
}:
buildPythonPackage rec {
pname = "python-louvain";
version = "0.16";
format = "setuptools";
src = fetchPypi {
inherit pname version;
hash = "sha256-t7ot9QAv0o0+54mklTK6rRH+ZI5PIRfPB5jnUgodpWs=";
};
patches = [
# Fix test_karate
(fetchpatch {
name = "fix-karate-test-networkx-2.7.patch";
url = "https://github.com/taynaud/python-louvain/pull/95/commits/c95d767e72f580cb15319fe08d72d87c9976640b.patch";
hash = "sha256-9oJ9YvKl2sI8oGhfyauNS+HT4kXsDt0L8S2owluWdj0=";
})
];
propagatedBuildInputs = [
networkx
numpy
];
pythonImportsCheck = [ "community" ];
nativeCheckInputs = [
pandas
scipy
];
meta = {
homepage = "https://github.com/taynaud/python-louvain";
description = "Louvain Community Detection";
mainProgram = "community";
license = lib.licenses.bsd3;
maintainers = [ ];
};
}