nixpkgs/pkgs/development/python-modules/jsonrpc-websocket/default.nix
Martin Weinelt 0215034f25 python3.pkgs: Migrate fetchers to use hash
when they already rely on SRI hashes.
2023-03-03 23:59:29 +01:00

51 lines
926 B
Nix

{ lib
, buildPythonPackage
, fetchFromGitHub
, aiohttp
, jsonrpc-base
, pytest-asyncio
, pytestCheckHook
, pythonOlder
}:
buildPythonPackage rec {
pname = "jsonrpc-websocket";
version = "3.1.4";
format = "setuptools";
disabled = pythonOlder "3.6";
src = fetchFromGitHub {
owner = "emlove";
repo = "jsonrpc-websocket";
rev = version;
hash = "sha256-xSOITOVtsNMEDrq610l8LNipLdyMWzKOQDedQEGaNOQ=";
};
propagatedBuildInputs = [
aiohttp
jsonrpc-base
];
nativeCheckInputs = [
pytestCheckHook
pytest-asyncio
];
pytestFlagsArray = [
"--asyncio-mode=auto"
"tests.py"
];
pythonImportsCheck = [
"jsonrpc_websocket"
];
meta = with lib; {
description = "A JSON-RPC websocket client library for asyncio";
homepage = "https://github.com/emlove/jsonrpc-websocket";
license = licenses.bsd3;
maintainers = with maintainers; [ peterhoeg ];
};
}