nix-bitcoin/pkgs/python-packages/pyln-client/default.nix
Erik Arvstedt f234e59ca5
nbPython3Packages: fix clightning pkgs
Also enable tests for the pyln-* pkgs.
2022-05-06 13:36:06 +00:00

28 lines
675 B
Nix

{ buildPythonPackage, poetry-core, pytestCheckHook, clightning, pyln-bolt7, pyln-proto }:
buildPythonPackage rec {
pname = "pyln-client";
version = clightning.version;
format = "pyproject";
inherit (clightning) src;
nativeBuildInputs = [ poetry-core ];
propagatedBuildInputs = [
pyln-bolt7
pyln-proto
];
checkInputs = [ pytestCheckHook ];
postUnpack = "sourceRoot=$sourceRoot/contrib/${pname}";
# Fix version typo in pyproject.toml
# TODO-EXTERNAL:
# This is already fixed upstream. Remove this after the next clightning release.
postPatch = ''
sed -i 's|pyln-bolt7 = "^1.0.186"|pyln-bolt7 = "^1.0.2.186"|' pyproject.toml
'';
}