1{
2 lib,
3 aiohttp,
4 aioresponses,
5 buildPythonPackage,
6 fetchFromGitHub,
7 orjson,
8 pytest-asyncio,
9 pytest-error-for-skips,
10 pytestCheckHook,
11 pythonOlder,
12 setuptools,
13 syrupy,
14}:
15
16buildPythonPackage rec {
17 pname = "accuweather";
18 version = "4.2.2";
19 pyproject = true;
20
21 disabled = pythonOlder "3.12";
22
23 src = fetchFromGitHub {
24 owner = "bieniu";
25 repo = "accuweather";
26 tag = version;
27 hash = "sha256-ORxo92nfLGNRC+eWX4NrpoMgiCLbtfR5JA+23OT/L3Y=";
28 };
29
30 build-system = [ setuptools ];
31
32 dependencies = [
33 aiohttp
34 orjson
35 ];
36
37 nativeCheckInputs = [
38 aioresponses
39 pytest-asyncio
40 pytest-error-for-skips
41 pytestCheckHook
42 syrupy
43 ];
44
45 pythonImportsCheck = [ "accuweather" ];
46
47 meta = {
48 description = "Python wrapper for getting weather data from AccuWeather servers";
49 homepage = "https://github.com/bieniu/accuweather";
50 changelog = "https://github.com/bieniu/accuweather/releases/tag/${version}";
51 license = lib.licenses.asl20;
52 maintainers = with lib.maintainers; [ jamiemagee ];
53 };
54}