2021-02-05 17:12:51 +00:00
|
|
|
{ lib
|
|
|
|
, aiohttp
|
|
|
|
, buildPythonPackage
|
|
|
|
, cbor2
|
|
|
|
, fetchFromGitHub
|
|
|
|
, pycryptodomex
|
|
|
|
, pytestCheckHook
|
|
|
|
, pytest-vcr
|
|
|
|
, pytest-asyncio
|
|
|
|
, requests
|
2022-01-27 00:19:43 +00:00
|
|
|
, pythonOlder
|
2021-02-05 17:12:51 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "pubnub";
|
2023-01-20 10:41:00 +00:00
|
|
|
version = "7.1.0";
|
2022-01-27 00:19:43 +00:00
|
|
|
format = "setuptools";
|
|
|
|
|
|
|
|
disabled = pythonOlder "3.7";
|
2021-02-05 17:12:51 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = pname;
|
|
|
|
repo = "python";
|
2022-09-09 14:08:57 +00:00
|
|
|
rev = "refs/tags/${version}";
|
2023-01-20 10:41:00 +00:00
|
|
|
hash = "sha256-+g/VBxv0XfqqwTEKtgBAy7Pfakll00JXMFBS2q3pHn8=";
|
2021-02-05 17:12:51 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
propagatedBuildInputs = [
|
2021-04-08 16:26:57 +00:00
|
|
|
aiohttp
|
2021-02-05 17:12:51 +00:00
|
|
|
cbor2
|
|
|
|
pycryptodomex
|
|
|
|
requests
|
|
|
|
];
|
|
|
|
|
|
|
|
checkInputs = [
|
|
|
|
pytest-asyncio
|
|
|
|
pytest-vcr
|
2022-01-27 00:19:43 +00:00
|
|
|
pytestCheckHook
|
2021-02-05 17:12:51 +00:00
|
|
|
];
|
|
|
|
|
2021-04-08 16:26:57 +00:00
|
|
|
disabledTestPaths = [
|
2022-01-27 00:19:43 +00:00
|
|
|
# Tests require network access
|
2021-04-08 16:26:57 +00:00
|
|
|
"tests/integrational"
|
2022-01-27 00:19:43 +00:00
|
|
|
"tests/manual"
|
|
|
|
"tests/functional/push"
|
2021-02-05 17:12:51 +00:00
|
|
|
];
|
|
|
|
|
2022-01-27 00:19:43 +00:00
|
|
|
pythonImportsCheck = [
|
|
|
|
"pubnub"
|
|
|
|
];
|
2021-02-05 17:12:51 +00:00
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Python-based APIs for PubNub";
|
|
|
|
homepage = "https://github.com/pubnub/python";
|
2022-11-27 09:42:12 +00:00
|
|
|
changelog = "https://github.com/pubnub/python/releases/tag/${version}";
|
2021-02-05 17:12:51 +00:00
|
|
|
license = with licenses; [ mit ];
|
|
|
|
maintainers = with maintainers; [ fab ];
|
|
|
|
};
|
|
|
|
}
|