1{ 2 sparqlwrapper, 3 boto3, 4 buildPythonPackage, 5 fetchFromGitHub, 6 gremlinpython, 7 jsonpath-ng, 8 lib, 9 moto, 10 openpyxl, 11 opensearch-py, 12 pandas, 13 pg8000, 14 poetry-core, 15 progressbar2, 16 pyarrow, 17 pymysql, 18 pyodbc, 19 pyparsing, 20 pytestCheckHook, 21 pythonOlder, 22 redshift-connector, 23 requests-aws4auth, 24 setuptools, 25}: 26 27buildPythonPackage rec { 28 pname = "awswrangler"; 29 version = "3.11.0"; 30 pyproject = true; 31 32 disabled = pythonOlder "3.8"; 33 34 src = fetchFromGitHub { 35 owner = "aws"; 36 repo = "aws-sdk-pandas"; 37 tag = version; 38 hash = "sha256-dIdNrfhBrfrzXmspw25yd/y6MbXRrLfDveCQk+AERV0="; 39 }; 40 41 pythonRelaxDeps = [ 42 "packaging" 43 "pyarrow" 44 ]; 45 46 build-system = [ poetry-core ]; 47 48 dependencies = [ 49 boto3 50 gremlinpython 51 jsonpath-ng 52 openpyxl 53 opensearch-py 54 pandas 55 pg8000 56 progressbar2 57 pyarrow 58 pymysql 59 redshift-connector 60 requests-aws4auth 61 setuptools 62 ]; 63 64 optional-dependencies = { 65 sqlserver = [ pyodbc ]; 66 sparql = [ sparqlwrapper ]; 67 }; 68 69 nativeCheckInputs = [ 70 moto 71 pyparsing 72 pytestCheckHook 73 ]; 74 75 pythonImportsCheck = [ "awswrangler" ]; 76 77 pytestFlagsArray = [ 78 # Subset of tests that run in upstream CI (many others require credentials) 79 # https://github.com/aws/aws-sdk-pandas/blob/20fec775515e9e256e8cee5aee12966516608840/.github/workflows/minimal-tests.yml#L36-L43 80 "tests/unit/test_metadata.py" 81 "tests/unit/test_session.py" 82 "tests/unit/test_utils.py" 83 "tests/unit/test_moto.py" 84 ]; 85 86 meta = with lib; { 87 description = "Pandas on AWS"; 88 homepage = "https://github.com/aws/aws-sdk-pandas"; 89 changelog = "https://github.com/aws/aws-sdk-pandas/releases/tag/${version}"; 90 license = licenses.asl20; 91 maintainers = with maintainers; [ mcwitt ]; 92 }; 93}