1{
2 lib,
3 anyconfig,
4 buildPythonPackage,
5 fetchFromGitHub,
6 isodate,
7 pytestCheckHook,
8 pythonOlder,
9 pyyaml,
10 requests,
11 responses,
12 poetry-core,
13 pythonRelaxDepsHook,
14}:
15
16buildPythonPackage rec {
17 pname = "pysolcast";
18 version = "2.0.2";
19 pyproject = true;
20
21 disabled = pythonOlder "3.9";
22
23 src = fetchFromGitHub {
24 owner = "mcaulifn";
25 repo = "solcast";
26 rev = "refs/tags/v${version}";
27 hash = "sha256-DXJkbAlkxBjUEbziFNdr8SilB2GRUoAwvrr0HY56Deg=";
28 };
29
30 pythonRelaxDeps = [ "responses" ];
31
32 build-system = [ poetry-core ];
33
34 nativeBuildInputs = [ pythonRelaxDepsHook ];
35
36 dependencies = [
37 anyconfig
38 isodate
39 pyyaml
40 requests
41 ];
42
43 nativeCheckInputs = [
44 pytestCheckHook
45 responses
46 ];
47
48 pythonImportsCheck = [ "pysolcast" ];
49
50 meta = with lib; {
51 description = "Python library for interacting with the Solcast API";
52 homepage = "https://github.com/mcaulifn/solcast";
53 changelog = "https://github.com/mcaulifn/solcast/releases/tag/v${version}";
54 license = with licenses; [ asl20 ];
55 maintainers = with maintainers; [ fab ];
56 };
57}