depot/third_party/nixpkgs/pkgs/development/python-modules/pyowm/default.nix
Default email 75ca762b89 Project import generated by Copybara.
GitOrigin-RevId: 29b0d4d0b600f8f5dd0b86e3362a33d4181938f9
2021-03-09 11:18:52 +08:00

42 lines
830 B
Nix

{ lib
, buildPythonPackage
, fetchFromGitHub
, geojson
, pysocks
, pythonOlder
, requests
, pytestCheckHook
}:
buildPythonPackage rec {
pname = "pyowm";
version = "3.2.0";
disabled = pythonOlder "3.7";
src = fetchFromGitHub {
owner = "csparpa";
repo = pname;
rev = version;
sha256 = "0sq8rxcgdiayl5gy4qhkvvsdq1d93sbzn0nfg8f1vr8qxh8qkfq4";
};
propagatedBuildInputs = [
geojson
pysocks
requests
];
checkInputs = [ pytestCheckHook ];
# Run only tests which don't require network access
pytestFlagsArray = [ "tests/unit" ];
pythonImportsCheck = [ "pyowm" ];
meta = with lib; {
description = "Python wrapper around the OpenWeatherMap web API";
homepage = "https://pyowm.readthedocs.io/";
license = licenses.mit;
maintainers = with maintainers; [ fab ];
};
}