1{ lib 2, buildPythonPackage 3, python-dateutil 4, fetchFromGitHub 5, fetchpatch 6, mock 7, msgpack 8, nose 9, pandas 10, pytestCheckHook 11, pytz 12, requests 13, requests-mock 14, six 15}: 16 17buildPythonPackage rec { 18 pname = "influxdb"; 19 version = "5.3.0"; 20 21 src = fetchFromGitHub { 22 owner = "influxdata"; 23 repo = "influxdb-python"; 24 rev = "v${version}"; 25 sha256 = "1jfkf53jcf8lcq98qc0bw5d1d0yp3558mh8l2dqc9jlsm0smigjs"; 26 }; 27 28 propagatedBuildInputs = [ 29 requests 30 python-dateutil 31 pytz 32 six 33 msgpack 34 ]; 35 36 checkInputs = [ 37 pytestCheckHook 38 requests-mock 39 mock 40 nose 41 pandas 42 ]; 43 44 patches = [ 45 (fetchpatch { 46 # Relaxes msgpack pinning 47 url = "https://github.com/influxdata/influxdb-python/commit/cc41e290f690c4eb67f75c98fa9f027bdb6eb16b.patch"; 48 sha256 = "1fb9qrq1kp24pixjwvzhdy67z3h0wnj92aj0jw0a25fd0rdxdvg4"; 49 }) 50 ]; 51 52 disabledTests = [ 53 # Tests cause FutureWarning due to use of 'record' instead of 'records' in pandas. 54 # https://github.com/influxdata/influxdb-python/pull/845 55 # Also type mismatches in assertEqual on DataFrame: 56 # b'foo[30 chars]_one=1.0,column_two=1.0 0\nfoo,tag_one=red,tag[47 chars]00\n' != 57 # b'foo[30 chars]_one="1",column_two=1i 0\nfoo,tag_one=red,tag_[46 chars]00\n' 58 "test_write_points_from_dataframe_with_nan_json" 59 "test_write_points_from_dataframe_with_tags_and_nan_json" 60 # Reponse is not empty but `s = '孝'` and the JSON decoder chokes on that 61 "test_query_with_empty_result" 62 ]; 63 64 pythonImportsCheck = [ "influxdb" ]; 65 66 meta = with lib; { 67 description = "Python client for InfluxDB"; 68 homepage = "https://github.com/influxdb/influxdb-python"; 69 license = licenses.mit; 70 maintainers = with maintainers; [ fab ]; 71 }; 72}