depot/third_party/nixpkgs/pkgs/development/python-modules/caldav/default.nix
Default email 5557ff764c Project import generated by Copybara.
GitOrigin-RevId: 988cc958c57ce4350ec248d2d53087777f9e1949
2023-02-22 11:55:15 +01:00

58 lines
1.1 KiB
Nix

{ lib
, buildPythonPackage
, fetchFromGitHub
, icalendar
, lxml
, pytestCheckHook
, pytz
, recurring-ical-events
, requests
, six
, tzlocal
, vobject
}:
buildPythonPackage rec {
pname = "caldav";
version = "1.1.1";
format = "setuptools";
src = fetchFromGitHub {
owner = "python-caldav";
repo = pname;
rev = "refs/tags/v${version}";
hash = "sha256-nAvkzZcMl/h1rysF6YNjEbbLrQ4PYGrXCoKgZEyE6WI=";
};
propagatedBuildInputs = [
vobject
lxml
requests
six
icalendar
recurring-ical-events
];
nativeCheckInputs = [
pytestCheckHook
tzlocal
pytz
];
# xandikos and radicale are only optional test dependencies, not available for python3
postPatch = ''
substituteInPlace setup.py \
--replace xandikos "" \
--replace radicale ""
'';
pythonImportsCheck = [ "caldav" ];
meta = with lib; {
description = "CalDAV (RFC4791) client library";
homepage = "https://github.com/python-caldav/caldav";
license = licenses.asl20;
maintainers = with maintainers; [ marenz dotlambda ];
};
}