1{ lib
2, fetchPypi
3, bitcoin-utils-fork-minimal
4, buildPythonPackage
5, base58
6, pycryptodome
7, requests
8, setuptools
9, pythonOlder
10}:
11
12buildPythonPackage rec {
13 pname = "block-io";
14 version = "2.0.6";
15 format = "setuptools";
16
17 disabled = pythonOlder "3.6";
18
19 src = fetchPypi {
20 inherit pname version;
21 hash = "sha256-M7czfpagXqoWWSu4enB3Z2hc2GtAaskI6cnJzJdpC8I=";
22 };
23
24 propagatedBuildInputs = [
25 base58
26 bitcoin-utils-fork-minimal
27 pycryptodome
28 requests
29 setuptools
30 ];
31
32 preConfigure = ''
33 substituteInPlace setup.py \
34 --replace "base58==2.1.0" "base58>=2.1.0"
35 '';
36
37 # Tests needs a BlockIO API key to run properly
38 # https://github.com/BlockIo/block_io-python/blob/79006bc8974544b70a2d8e9f19c759941d32648e/test.py#L18
39 doCheck = false;
40
41 pythonImportsCheck = [
42 "block_io"
43 ];
44
45 meta = with lib; {
46 description = "Integrate Bitcoin, Dogecoin and Litecoin in your Python applications using block.io";
47 homepage = "https://github.com/BlockIo/block_io-python";
48 license = licenses.mit;
49 maintainers = with maintainers; [ nyanloutre ];
50 };
51}