1{
2 lib,
3 buildPythonPackage,
4 fetchFromGitHub,
5 pytestCheckHook,
6 pythonOlder,
7 requests,
8 responses,
9 setuptools,
10}:
11
12buildPythonPackage rec {
13 pname = "python-twitch-client";
14 version = "0.7.1";
15 pyproject = true;
16
17 disabled = pythonOlder "3.6";
18
19 src = fetchFromGitHub {
20 owner = "tsifrer";
21 repo = "python-twitch-client";
22 tag = version;
23 sha256 = "sha256-gxBpltwExb9bg3HLkz/MNlP5Q3/x97RHxhbwNqqanIM=";
24 };
25
26 nativeBuildInputs = [ setuptools ];
27
28 propagatedBuildInputs = [ requests ];
29
30 nativeCheckInputs = [
31 pytestCheckHook
32 responses
33 ];
34
35 pythonImportsCheck = [ "twitch" ];
36
37 disabledTests = [
38 # Tests require network access
39 "test_delete_from_community"
40 "test_update"
41 ];
42
43 meta = with lib; {
44 description = "Python wrapper for the Twitch API";
45 homepage = "https://github.com/tsifrer/python-twitch-client";
46 changelog = "https://github.com/tsifrer/python-twitch-client/blob/${version}/CHANGELOG.md";
47 license = with licenses; [ mit ];
48 maintainers = with maintainers; [ fab ];
49 };
50}