depot/third_party/nixpkgs/pkgs/development/python-modules/databricks-connect/default.nix
Default email d9e13ed064 Project import generated by Copybara.
GitOrigin-RevId: a930f7da84786807bb105df40e76b541604c3e72
2021-09-22 23:38:15 +08:00

37 lines
918 B
Nix

{ lib, jdk, buildPythonPackage, fetchPypi, six, py4j }:
buildPythonPackage rec {
pname = "databricks-connect";
version = "8.1.13";
src = fetchPypi {
inherit pname version;
sha256 = "2833679bccd507e3eac9ec931cfae85c8070a78ad1286159475b7d3b79a40dc2";
};
sourceRoot = ".";
propagatedBuildInputs = [ py4j six jdk ];
# requires network access
doCheck = false;
prePatch = ''
substituteInPlace setup.py \
--replace "py4j==0.10.9" "py4j"
'';
preFixup = ''
substituteInPlace "$out/bin/find-spark-home" \
--replace find_spark_home.py .find_spark_home.py-wrapped
'';
pythonImportsCheck = [ "pyspark" "six" "py4j" ];
meta = with lib; {
description = "Client for connecting to remote Databricks clusters";
homepage = "https://pypi.org/project/databricks-connect";
license = licenses.databricks;
maintainers = with maintainers; [ kfollesdal ];
};
}