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

49 lines
991 B
Nix

{ lib
, buildPythonPackage
, fetchFromGitHub
, pythonOlder
, pytestrunner
, aiohttp
, aioresponses
, pytestCheckHook
, pytestcov
, pytest-asyncio
}:
buildPythonPackage rec {
pname = "accuweather";
version = "0.1.0";
disabled = pythonOlder "3.6";
src = fetchFromGitHub {
owner = "bieniu";
repo = pname;
rev = version;
sha256 = "0jp2x7fgg1shgr1fx296rni00lmjjmjgg141giljzizgd04dwgy3";
};
postPatch = ''
# we don't have pytest-error-for-skips packaged
substituteInPlace pytest.ini --replace "--error-for-skips" ""
'';
nativeBuildInputs = [ pytestrunner ];
propagatedBuildInputs = [ aiohttp ];
checkInputs = [
aioresponses
pytestCheckHook
pytestcov
pytest-asyncio
];
meta = with lib; {
description =
"Python wrapper for getting weather data from AccuWeather servers.";
homepage = "https://github.com/bieniu/accuweather";
license = licenses.asl20;
maintainers = with maintainers; [ jamiemagee ];
};
}