Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
1{
2 lib,
3 buildPythonPackage,
4 fetchFromGitHub,
5 setuptools,
6 eth-hash,
7 eth-utils,
8 hexbytes,
9 pytestCheckHook,
10 rlp,
11 pydantic,
12}:
13
14buildPythonPackage rec {
15 pname = "eth-rlp";
16 version = "2.2.0";
17 pyproject = true;
18
19 src = fetchFromGitHub {
20 owner = "ethereum";
21 repo = "eth-rlp";
22 rev = "v${version}";
23 hash = "sha256-e8nPfxk3OnFEcPnfTy1IEUCHVId6E/ssNOUeAe331+U=";
24 };
25
26 build-system = [ setuptools ];
27
28 propagatedBuildInputs = [
29 hexbytes
30 eth-utils
31 rlp
32 ];
33
34 nativeCheckInputs = [
35 pytestCheckHook
36 pydantic
37 ]
38 ++ eth-hash.optional-dependencies.pycryptodome;
39
40 pythonImportsCheck = [ "eth_rlp" ];
41
42 disabledTests = [
43 "test_install_local_wheel"
44 ];
45
46 meta = {
47 description = "RLP definitions for common Ethereum objects";
48 homepage = "https://github.com/ethereum/eth-rlp";
49 license = lib.licenses.mit;
50 maintainers = [ ];
51 };
52}