1{ 2 lib, 3 buildPythonPackage, 4 docopt, 5 fetchPypi, 6 nose, 7 pytz, 8 pythonOlder, 9 setuptools-scm, 10 six, 11 sqlalchemy, 12}: 13 14buildPythonPackage rec { 15 pname = "pygtfs"; 16 version = "0.1.9"; 17 format = "setuptools"; 18 19 disabled = pythonOlder "3.7"; 20 21 src = fetchPypi { 22 inherit pname version; 23 hash = "sha256-J5vu51OOMabWd8h60PpvvBiCnwQlhEnBywNXxy9hOuA="; 24 }; 25 26 postPatch = '' 27 # https://github.com/jarondl/pygtfs/pull/72 28 substituteInPlace setup.py \ 29 --replace "pytz>=2012d" "pytz" 30 ''; 31 32 nativeBuildInputs = [ setuptools-scm ]; 33 34 propagatedBuildInputs = [ 35 docopt 36 pytz 37 six 38 sqlalchemy 39 ]; 40 41 nativeCheckInputs = [ nose ]; 42 43 pythonImportsCheck = [ "pygtfs" ]; 44 45 meta = with lib; { 46 description = "Python module for GTFS"; 47 mainProgram = "gtfs2db"; 48 homepage = "https://github.com/jarondl/pygtfs"; 49 license = with licenses; [ mit ]; 50 maintainers = with maintainers; [ fab ]; 51 }; 52}