at 24.05-pre 995 B view raw
1{ lib 2, buildPythonPackage 3, fetchFromGitHub 4, geojson 5, pysocks 6, pythonOlder 7, requests 8, pytestCheckHook 9, pythonRelaxDepsHook 10}: 11 12buildPythonPackage rec { 13 pname = "pyowm"; 14 version = "3.3.0"; 15 format = "setuptools"; 16 17 disabled = pythonOlder "3.7"; 18 19 src = fetchFromGitHub { 20 owner = "csparpa"; 21 repo = pname; 22 rev = version; 23 hash = "sha256-cSOhm3aDksLBChZzgw1gjUjLQkElR2/xGFMOb9K9RME="; 24 }; 25 26 pythonRelaxDeps = [ 27 "geojson" 28 ]; 29 30 nativeBuildInputs = [ 31 pythonRelaxDepsHook 32 ]; 33 34 propagatedBuildInputs = [ 35 geojson 36 pysocks 37 requests 38 ]; 39 40 nativeCheckInputs = [ 41 pytestCheckHook 42 ]; 43 44 # Run only tests which don't require network access 45 pytestFlagsArray = [ 46 "tests/unit" 47 ]; 48 49 pythonImportsCheck = [ 50 "pyowm" 51 ]; 52 53 meta = with lib; { 54 description = "Python wrapper around the OpenWeatherMap web API"; 55 homepage = "https://pyowm.readthedocs.io/"; 56 license = licenses.mit; 57 maintainers = with maintainers; [ fab ]; 58 }; 59}