You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by GitBox <gi...@apache.org> on 2020/04/20 12:40:46 UTC

[GitHub] [spark] HyukjinKwon commented on a change in pull request #28256: [SPARK-31483][PySpark] Use SPARK_PYTHON or 'python' to run find_spark_home.py

HyukjinKwon commented on a change in pull request #28256:
URL: https://github.com/apache/spark/pull/28256#discussion_r411344170



##########
File path: bin/find-spark-home
##########
@@ -34,8 +34,5 @@ elif [ ! -f "$FIND_SPARK_HOME_PYTHON_SCRIPT" ]; then
 else
   # We are pip installed, use the Python script to resolve a reasonable SPARK_HOME
   # Default to standard python interpreter unless told otherwise
-  if [[ -z "$PYSPARK_DRIVER_PYTHON" ]]; then
-     PYSPARK_DRIVER_PYTHON="${PYSPARK_PYTHON:-"python"}"
-  fi
-  export SPARK_HOME=$($PYSPARK_DRIVER_PYTHON "$FIND_SPARK_HOME_PYTHON_SCRIPT")
+  export SPARK_HOME=$(${PYSPARK_PYTHON:-"python"} "$FIND_SPARK_HOME_PYTHON_SCRIPT")

Review comment:
       Hmmm .. can we strip the non-printable characters instead?
   Respecting `PYSPARK_DRIVER_PYTHON` falling back to `PYSPARK_PYTHON` is expected. 




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org