2022-03-05 16:20:37 +00:00
|
|
|
{ lib
|
|
|
|
, buildPythonPackage
|
2022-06-16 17:23:12 +00:00
|
|
|
, pythonOlder
|
2023-10-09 19:29:22 +00:00
|
|
|
, fetchFromGitHub
|
|
|
|
, setuptools
|
2022-03-05 16:20:37 +00:00
|
|
|
, aiohttp
|
|
|
|
, python-dateutil
|
|
|
|
, typing-extensions
|
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "twitchapi";
|
2024-02-29 20:09:43 +00:00
|
|
|
version = "4.2.0";
|
2022-06-16 17:23:12 +00:00
|
|
|
|
|
|
|
disabled = pythonOlder "3.7";
|
2022-03-05 16:20:37 +00:00
|
|
|
|
2024-02-29 20:09:43 +00:00
|
|
|
pyproject = true;
|
2022-03-05 16:20:37 +00:00
|
|
|
|
2023-10-09 19:29:22 +00:00
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "Teekeks";
|
|
|
|
repo = "pyTwitchAPI";
|
|
|
|
rev = "refs/tags/v${version}";
|
2024-02-29 20:09:43 +00:00
|
|
|
hash = "sha256-QAxLYujnsudaiz9UepwrBA835Pct5h4VcE9ZrbkwMmg=";
|
2022-03-05 16:20:37 +00:00
|
|
|
};
|
|
|
|
|
2023-10-09 19:29:22 +00:00
|
|
|
nativeBuildInputs = [
|
|
|
|
setuptools
|
|
|
|
];
|
|
|
|
|
2022-03-05 16:20:37 +00:00
|
|
|
propagatedBuildInputs = [
|
|
|
|
aiohttp
|
|
|
|
python-dateutil
|
|
|
|
typing-extensions
|
|
|
|
];
|
|
|
|
|
|
|
|
# upstream has no tests
|
|
|
|
doCheck = false;
|
|
|
|
|
|
|
|
pythonImportsCheck = [
|
|
|
|
"twitchAPI.eventsub"
|
|
|
|
"twitchAPI.oauth"
|
|
|
|
"twitchAPI.pubsub"
|
|
|
|
"twitchAPI.twitch"
|
2023-10-09 19:29:22 +00:00
|
|
|
"twitchAPI.type"
|
2022-03-05 16:20:37 +00:00
|
|
|
];
|
|
|
|
|
|
|
|
meta = with lib; {
|
2023-10-09 19:29:22 +00:00
|
|
|
changelog = "https://github.com/Teekeks/pyTwitchAPI/blob/${src.rev}/docs/changelog.rst";
|
2022-03-05 16:20:37 +00:00
|
|
|
description = "Python implementation of the Twitch Helix API, its Webhook, PubSub and EventSub";
|
|
|
|
homepage = "https://github.com/Teekeks/pyTwitchAPI";
|
|
|
|
license = licenses.mit;
|
2022-03-10 19:12:11 +00:00
|
|
|
maintainers = with maintainers; [ dotlambda wolfangaukang ];
|
2022-03-05 16:20:37 +00:00
|
|
|
};
|
|
|
|
}
|