nixpkgs/pkgs/development/python-modules/watchdog/default.nix

50 lines
1020 B
Nix
Raw Normal View History

{ lib
, stdenv
, buildPythonPackage
, fetchPypi
, argh
, pathtools
, pyyaml
2021-02-01 22:32:12 +00:00
, pytestCheckHook
, CoreServices
}:
buildPythonPackage rec {
pname = "watchdog";
version = "2.0.3";
src = fetchPypi {
inherit pname version;
sha256 = "sha256-QojTqYQyTbSS5XqhaWZiOKJXjwr1oIFoVSZgj7n2vWE=";
};
buildInputs = lib.optionals stdenv.isDarwin [ CoreServices ];
2021-02-01 22:32:12 +00:00
propagatedBuildInputs = [
argh
pathtools
pyyaml
];
checkInputs = [
pytestCheckHook
];
postPatch = ''
substituteInPlace setup.cfg \
--replace "--cov=watchdog" "" \
--replace "--cov-report=term-missing" ""
'';
2021-02-01 22:32:12 +00:00
pythonImportsCheck = [ "watchdog" ];
meta = with lib; {
description = "Python API and shell utilities to monitor file system events";
homepage = "https://github.com/gorakhargosh/watchdog";
license = licenses.asl20;
maintainers = with maintainers; [ goibhniu ];
# error: use of undeclared identifier 'kFSEventStreamEventFlagItemCloned'
broken = stdenv.isDarwin;
};
}