1{ lib
2, buildPythonPackage
3, fetchFromGitHub
4, pytz
5, unittest2
6, isPy27
7}:
8
9buildPythonPackage rec {
10 pname = "ciso8601";
11 version = "2.2.0";
12
13 src = fetchFromGitHub {
14 owner = "closeio";
15 repo = "ciso8601";
16 rev = "v${version}";
17 sha256 = "sha256-TqB1tQDgCkXu+QuzP6yBEH/xHxhhD/kGR2S0I8Osc5E=";
18 };
19
20 checkInputs = [
21 pytz
22 ] ++ lib.optionals (isPy27) [
23 unittest2
24 ];
25
26 pythonImportsCheck = [ "ciso8601" ];
27
28 meta = with lib; {
29 description = "Fast ISO8601 date time parser for Python written in C";
30 homepage = "https://github.com/closeio/ciso8601";
31 license = licenses.mit;
32 maintainers = with maintainers; [ mic92 ];
33 };
34}