depot/third_party/nixpkgs/pkgs/development/python-modules/pyowm/default.nix
Default email 2ce89355c3 Project import generated by Copybara.
GitOrigin-RevId: 22a81aa5fc15b2d41b12f7160a71cd4a9f3c3fa1
2020-06-15 17:56:04 +02:00

30 lines
725 B
Nix

{ lib, buildPythonPackage, fetchPypi, pythonOlder, requests, geojson }:
buildPythonPackage rec {
pname = "pyowm";
version = "3.0.0";
disabled = pythonOlder "3.3";
src = fetchPypi {
inherit pname version;
sha256 = "f06ac5f2356f0964f088b1f840a6d382499054bd18539ffb1e7c84f29c2c39b6";
};
propagatedBuildInputs = [ requests geojson ];
# This may actually break the package.
postPatch = ''
substituteInPlace setup.py \
--replace "requests>=2.18.2,<2.19" "requests"
'';
# No tests in archive
doCheck = false;
meta = with lib; {
description = "A Python wrapper around the OpenWeatherMap web API";
homepage = "https://pyowm.readthedocs.io/";
license = licenses.mit;
};
}