about summary refs log tree commit diff
path: root/pkgs/development/python-modules/pygti/default.nix
blob: 6db8efa7aa31066563d0d06ed835b982ea449643 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
{ lib
, buildPythonPackage
, pythonOlder
, fetchFromGitHub
, setuptools-scm
, aiohttp
, pytz
, voluptuous
}:

buildPythonPackage rec {
  pname = "pygti";
  version = "0.9.4";
  format = "setuptools";

  disabled = pythonOlder "3.6";

  src = fetchFromGitHub {
    owner = "vigonotion";
    repo = "pygti";
    rev = "refs/tags/v${version}";
    hash = "sha256-2T4Yw4XEOkv+IWyB4Xa2dPu929VH0tLeUjQ5S8EVXz0=";
  };

  nativeBuildInputs = [
    setuptools-scm
  ];

  SETUPTOOLS_SCM_PRETEND_VERSION = version;

  propagatedBuildInputs = [
    aiohttp
    pytz
    voluptuous
  ];

  # no tests implemented
  doCheck = false;

  pythonImportsCheck = [
    "pygti.auth"
    "pygti.exceptions"
    "pygti.gti"
  ];

  meta = with lib; {
    description = "Access public transport information in Hamburg, Germany";
    homepage = "https://github.com/vigonotion/pygti";
    license = licenses.asl20;
    maintainers = with maintainers; [ dotlambda ];
  };
}