2023-07-15 17:15:38 +00:00
|
|
|
{ lib
|
|
|
|
, buildPythonPackage
|
|
|
|
, fetchFromGitHub
|
|
|
|
, hatchling
|
|
|
|
, mkdocs-material
|
|
|
|
, mkdocs-mermaid2-plugin
|
|
|
|
, mkdocstrings
|
2023-10-09 19:29:22 +00:00
|
|
|
, networkx
|
|
|
|
, pygraphviz
|
|
|
|
, pytestCheckHook
|
|
|
|
, pythonOlder
|
|
|
|
, requests
|
2023-07-15 17:15:38 +00:00
|
|
|
}:
|
2023-10-09 19:29:22 +00:00
|
|
|
|
|
|
|
buildPythonPackage rec {
|
2023-07-15 17:15:38 +00:00
|
|
|
pname = "canals";
|
2023-10-09 19:29:22 +00:00
|
|
|
version = "0.8.1";
|
2023-07-15 17:15:38 +00:00
|
|
|
format = "pyproject";
|
|
|
|
|
2023-10-09 19:29:22 +00:00
|
|
|
disabled = pythonOlder "3.8";
|
|
|
|
|
2023-07-15 17:15:38 +00:00
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "deepset-ai";
|
|
|
|
repo = pname;
|
2023-10-09 19:29:22 +00:00
|
|
|
rev = "refs/tags/v${version}";
|
|
|
|
hash = "sha256-XC4CxvDghz8/LReeYjHEVtd8j2ZN4jd+x7vP6N8BKpc=";
|
2023-07-15 17:15:38 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
nativeBuildInputs = [
|
|
|
|
hatchling
|
|
|
|
];
|
|
|
|
|
|
|
|
propagatedBuildInputs = [
|
|
|
|
networkx
|
|
|
|
];
|
|
|
|
|
2023-10-09 19:29:22 +00:00
|
|
|
passthru.optional-dependencies = {
|
|
|
|
graphviz = [
|
|
|
|
pygraphviz
|
|
|
|
];
|
|
|
|
mermaid = [
|
|
|
|
requests
|
|
|
|
];
|
|
|
|
docs = [
|
|
|
|
mkdocs-material
|
|
|
|
mkdocs-mermaid2-plugin
|
|
|
|
mkdocstrings
|
|
|
|
];
|
|
|
|
};
|
2023-07-15 17:15:38 +00:00
|
|
|
|
|
|
|
nativeCheckInputs = [
|
|
|
|
pytestCheckHook
|
2023-10-09 19:29:22 +00:00
|
|
|
] ++ lib.flatten (builtins.attrValues passthru.optional-dependencies);
|
2023-07-15 17:15:38 +00:00
|
|
|
|
|
|
|
disabledTestPaths = [
|
2023-10-09 19:29:22 +00:00
|
|
|
# Test requires internet connection to mermaid.ink
|
2023-07-15 17:15:38 +00:00
|
|
|
"test/pipelines/integration"
|
|
|
|
];
|
|
|
|
|
2023-10-09 19:29:22 +00:00
|
|
|
disabledTests = [
|
|
|
|
# Path issue
|
|
|
|
"test_draw_pygraphviz"
|
|
|
|
];
|
|
|
|
|
|
|
|
pythonImportsCheck = [
|
|
|
|
"canals"
|
|
|
|
];
|
2023-07-15 17:15:38 +00:00
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "A component orchestration engine";
|
|
|
|
homepage = "https://github.com/deepset-ai/canals";
|
|
|
|
changelog = "https://github.com/deepset-ai/canals/releases/tag/v${version}";
|
|
|
|
license = licenses.asl20;
|
|
|
|
maintainers = with maintainers; [ happysalada ];
|
|
|
|
};
|
|
|
|
}
|