nixpkgs mirror (for testing)
github.com/NixOS/nixpkgs
nix
1{ lib
2, buildPythonPackage
3, pythonOlder
4, asn1crypto
5, azure-storage-blob
6, boto3
7, certifi
8, cffi
9, fetchPypi
10, future
11, idna
12, ijson
13, oscrypto
14, pyarrow
15, pyasn1-modules
16, pycryptodomex
17, pyjwt
18, pyopenssl
19, pytz
20, requests
21, six
22, urllib3
23}:
24
25buildPythonPackage rec {
26 pname = "snowflake-connector-python";
27 version = "2.7.7";
28 disabled = pythonOlder "3.6";
29
30 src = fetchPypi {
31 inherit pname version;
32 sha256 = "sha256-OZL/ClHY8yatR0AJVyomBq7AjBwQwm5f9UnmdlL8IFw=";
33 };
34
35 postPatch = ''
36 substituteInPlace setup.cfg \
37 --replace "pyOpenSSL>=16.2.0,<22.0.0" "pyOpenSSL"
38 '';
39
40 propagatedBuildInputs = [
41 azure-storage-blob
42 asn1crypto
43 boto3
44 certifi
45 cffi
46 future
47 idna
48 ijson
49 oscrypto
50 pycryptodomex
51 pyjwt
52 pyopenssl
53 pytz
54 requests
55 six
56 pyarrow
57 pyasn1-modules
58 urllib3
59 ];
60
61 # Tests require encrypted secrets, see
62 # https://github.com/snowflakedb/snowflake-connector-python/tree/master/.github/workflows/parameters
63 doCheck = false;
64
65 pythonImportsCheck = [
66 "snowflake"
67 "snowflake.connector"
68 ];
69
70 meta = with lib; {
71 description = "Snowflake Connector for Python";
72 homepage = "https://www.snowflake.com/";
73 license = licenses.asl20;
74 maintainers = with maintainers; [ ];
75 };
76}