Merge pull request #119126 from fabaff/pycomfoconnect
[NixPkgs.git] / pkgs / development / python-modules / geopy / default.nix
blob693a4221ee092252ad57c5418e39f18362770bf6
1 { lib
2 , async_generator
3 , buildPythonPackage
4 , fetchFromGitHub
5 , geographiclib
6 , isPy3k
7 , pytestCheckHook
8 }:
10 buildPythonPackage rec {
11   pname = "geopy";
12   version = "2.1.0";
13   disabled = !isPy3k; # only Python 3
15   src = fetchFromGitHub {
16     owner = pname;
17     repo = pname;
18     rev = version;
19     sha256 = "0239a4achk49ngagb6aqy6cgzfwgbxir07vwi13ysbpx78y0l4g9";
20   };
22   propagatedBuildInputs = [ geographiclib ];
24   checkInputs = [
25     async_generator
26     pytestCheckHook
27   ];
29   # Exclude tests which perform API calls
30   pytestFlagsArray = [ "--ignore test/geocoders/" ];
31   pythonImportsCheck = [ "geopy" ];
33   __darwinAllowLocalNetworking = true;
35   meta = with lib; {
36     homepage = "https://github.com/geopy/geopy";
37     description = "Python Geocoding Toolbox";
38     changelog = "https://github.com/geopy/geopy/releases/tag/${version}";
39     license = with licenses; [ mit ];
40     maintainers = with maintainers; [ GuillaumeDesforges ];
41   };