1{
2 lib,
3 buildPythonPackage,
4 pythonOlder,
5 fetchFromGitHub,
6 setuptools,
7 aiohttp,
8 python-dateutil,
9 typing-extensions,
10}:
11
12buildPythonPackage rec {
13 pname = "twitchapi";
14 version = "4.2.0";
15
16 disabled = pythonOlder "3.7";
17
18 pyproject = true;
19
20 src = fetchFromGitHub {
21 owner = "Teekeks";
22 repo = "pyTwitchAPI";
23 rev = "refs/tags/v${version}";
24 hash = "sha256-QAxLYujnsudaiz9UepwrBA835Pct5h4VcE9ZrbkwMmg=";
25 };
26
27 nativeBuildInputs = [ setuptools ];
28
29 propagatedBuildInputs = [
30 aiohttp
31 python-dateutil
32 typing-extensions
33 ];
34
35 # upstream has no tests
36 doCheck = false;
37
38 pythonImportsCheck = [
39 "twitchAPI.eventsub"
40 "twitchAPI.oauth"
41 "twitchAPI.pubsub"
42 "twitchAPI.twitch"
43 "twitchAPI.type"
44 ];
45
46 meta = with lib; {
47 changelog = "https://github.com/Teekeks/pyTwitchAPI/blob/${src.rev}/docs/changelog.rst";
48 description = "Python implementation of the Twitch Helix API, its Webhook, PubSub and EventSub";
49 homepage = "https://github.com/Teekeks/pyTwitchAPI";
50 license = licenses.mit;
51 maintainers = with maintainers; [
52 dotlambda
53 wolfangaukang
54 ];
55 };
56}