Skip to content

Commit 0c9dd50

Browse files
committed
Avoid Unidoc build when Hadoop 2.6 is explicitly set.
1 parent f81b9fc commit 0c9dd50

File tree

1 file changed

+10
-2
lines changed

1 file changed

+10
-2
lines changed

dev/run-tests.py

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -365,8 +365,16 @@ def build_spark_assembly_sbt(hadoop_version):
365365
print("[info] Building Spark assembly (w/Hive 1.2.1) using SBT with these arguments: ",
366366
" ".join(profiles_and_goals))
367367
exec_sbt(profiles_and_goals)
368-
# Make sure that Java and Scala API documentation can be generated
369-
build_spark_unidoc_sbt(hadoop_version)
368+
369+
# Note that we skip Unidoc build only if Hadoop 2.6 is explicitly set in this SBT build.
370+
# Due to a different dependency resolution in SBT & Unidoc by an unknown reason, the
371+
# documentation build fails on a specific machine & environment in Jenkins but it was unable
372+
# to reproduce. Please see SPARK-20343. This is a band-aid fix that should be removed in
373+
# the future.
374+
is_hadoop_version_2_6 = os.environ.get("AMPLAB_JENKINS_BUILD_PROFILE") == "hadoop2.6"
375+
if not is_hadoop_version_2_6:
376+
# Make sure that Java and Scala API documentation can be generated
377+
build_spark_unidoc_sbt(hadoop_version)
370378

371379

372380
def build_apache_spark(build_tool, hadoop_version):

0 commit comments

Comments
 (0)