1{ lib
2, aiohttp
3, buildPythonPackage
4, dateparser
5, fetchFromGitHub
6, pytestCheckHook
7, pythonOlder
8, requests
9, requests-mock
10, six
11, ujson
12, websockets
13}:
14
15buildPythonPackage rec {
16 pname = "python-binance";
17 version = "1.0.10";
18 disabled = pythonOlder "3.6";
19
20 src = fetchFromGitHub {
21 owner = "sammchardy";
22 repo = pname;
23 rev = "v${version}";
24 sha256 = "09pq2blvky1ah4k8yc6zkp2g5nkn3awc52ad3lxvj6m33akfzxiv";
25 };
26
27 propagatedBuildInputs = [
28 aiohttp
29 dateparser
30 requests
31 six
32 ujson
33 websockets
34 ];
35
36 checkInputs = [
37 pytestCheckHook
38 requests-mock
39 ];
40
41 disabledTestPaths = [
42 # Tests require network access
43 "tests/test_api_request.py"
44 "tests/test_historical_klines.py"
45 ];
46
47 pythonImportsCheck = [ "binance" ];
48
49 meta = with lib; {
50 description = "Binance Exchange API python implementation for automated trading";
51 homepage = "https://github.com/sammchardy/python-binance";
52 license = licenses.mit;
53 maintainers = with maintainers; [ bhipple ];
54 };
55}