python3Packages.pyspark: update postPatch and add pythonImportsCheck

This commit is contained in:
Fabian Affolter 2021-10-19 08:52:32 +02:00 committed by GitHub
parent b131ad3c3e
commit 06c825a9c2
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1,4 +1,8 @@
{ buildPythonPackage, fetchPypi, lib, py4j }: { lib
, buildPythonPackage
, fetchPypi
, py4j
}:
buildPythonPackage rec { buildPythonPackage rec {
pname = "pyspark"; pname = "pyspark";
@ -13,16 +17,23 @@ buildPythonPackage rec {
postPatch = '' postPatch = ''
sed -i "s/'pypandoc'//" setup.py sed -i "s/'pypandoc'//" setup.py
substituteInPlace setup.py --replace py4j==0.10.9 'py4j>=0.10.9,<0.11' substituteInPlace setup.py \
--replace py4j==0.10.9.2 'py4j>=0.10.9,<0.11'
''; '';
propagatedBuildInputs = [ py4j ]; propagatedBuildInputs = [
py4j
];
# Tests assume running spark... # Tests assume running spark instance
doCheck = false; doCheck = false;
pythonImportsCheck = [
"pyspark"
];
meta = with lib; { meta = with lib; {
description = "Apache Spark"; description = "Python bindings for Apache Spark";
homepage = "https://github.com/apache/spark/tree/master/python"; homepage = "https://github.com/apache/spark/tree/master/python";
license = licenses.asl20; license = licenses.asl20;
maintainers = [ maintainers.shlevy ]; maintainers = [ maintainers.shlevy ];