[ 
https://issues.apache.org/jira/browse/SPARK-32102?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Jijo Sunny updated SPARK-32102:
-------------------------------
    Description: 
Java source code link in Spark api scaladoc is broken. This issue still 
persists for all Java files referred from scala doc.

The relative path expression "€\{FILE_PATH}.scala" in 
[https://github.com/apache/spark/blob/master/project/SparkBuild.scala] has 
".scala" hardcoded in the end. 

If I try to access the source link on 
[https://spark.apache.org/docs/2.4.4/api/scala/index.html#org.apache.spark.sql.sources.v2.DataSourceOptions],
 it tries to take me to 
[https://github.com/apache/spark/tree/v2.4.4/sql/core/src/main/java/org/apache/spark/sql/sources/v2/DataSourceOptions.java.scala]

This is coming from /project/SparkBuild.scala :

Line # 720
{code:scala}
// Use GitHub repository for Scaladoc source links
unidocSourceBase := s"https://github.com/apache/spark/tree/v${version.value}";,

scalacOptions in (ScalaUnidoc, unidoc) ++= Seq(
"-groups", // Group similar methods together based on the @group annotation.
"-skip-packages", "org.apache.hadoop"
) ++ (
// Add links to sources when generating Scaladoc for a non-snapshot release
if (!isSnapshot.value) {
Opts.doc.sourceUrl(unidocSourceBase.value + "€{FILE_PATH}.scala")
} else {
Seq()
}
){code}
 



  was:
Java source code link in Spark api scaladoc is broken.

The relative path expression "€\{FILE_PATH}.scala" in 
[https://github.com/apache/spark/blob/master/project/SparkBuild.scala] has 
".scala" hardcoded in the end. If I try to access the source link on 
[https://spark.apache.org/docs/2.4.4/api/scala/index.html#org.apache.spark.sql.sources.v2.DataSourceOptions],
 it tries to take me to 
[https://github.com/apache/spark/tree/v2.4.4/sql/core/src/main/java/org/apache/spark/sql/sources/v2/DataSourceOptions.java.scala]

This is coming from /project/SparkBuild.scala :

Line # 720
{code:scala}
// Use GitHub repository for Scaladoc source links
unidocSourceBase := s"https://github.com/apache/spark/tree/v${version.value}";,

scalacOptions in (ScalaUnidoc, unidoc) ++= Seq(
"-groups", // Group similar methods together based on the @group annotation.
"-skip-packages", "org.apache.hadoop"
) ++ (
// Add links to sources when generating Scaladoc for a non-snapshot release
if (!isSnapshot.value) {
Opts.doc.sourceUrl(unidocSourceBase.value + "€{FILE_PATH}.scala")
} else {
Seq()
}
){code}
 

 This issue still persists for all Java files referred from scala doc.


> Broken link to java source code in Spark Scala api doc
> ------------------------------------------------------
>
>                 Key: SPARK-32102
>                 URL: https://issues.apache.org/jira/browse/SPARK-32102
>             Project: Spark
>          Issue Type: Bug
>          Components: Build, Documentation, Project Infra
>    Affects Versions: 2.4.4, 2.4.5
>         Environment: {code:java}
> ~/spark/docs$ cat /etc/*release*
> DISTRIB_ID=Ubuntu
> DISTRIB_RELEASE=16.04
> DISTRIB_CODENAME=xenial
> DISTRIB_DESCRIPTION="Ubuntu 16.04.4 LTS"
> NAME="Ubuntu"
> VERSION="16.04.4 LTS (Xenial Xerus)"
> ID=ubuntu
> ID_LIKE=debian
> PRETTY_NAME="Ubuntu 16.04.4 LTS"
> VERSION_ID="16.04"
> HOME_URL="http://www.ubuntu.com/";
> SUPPORT_URL="http://help.ubuntu.com/";
> BUG_REPORT_URL="http://bugs.launchpad.net/ubuntu/";
> VERSION_CODENAME=xenial
> UBUNTU_CODENAME=xenial
> {code}
> Using spark packaged sbt.
> Other versions:
> {code:java}
> ~/spark/docs$ ruby -v 
> ruby 2.3.1p112 (2016-04-26) [x86_64-linux-gnu] 
> ~/spark/docs$ gem -v 
> 2.5.2.1 
> ~/spark/docs$ jekyll -v 
> jekyll 3.7.3  
> ~/spark/docs$ java -version 
> java version "1.8.0_112" Java(TM) SE Runtime Environment (build 
> 1.8.0_112-b15) Java HotSpot(TM) 64-Bit Server VM (build 25.112-b15, mixed 
> mode)
> {code}
>            Reporter: Jijo Sunny
>            Priority: Trivial
>              Labels: build, documentation, scaladocs
>
> Java source code link in Spark api scaladoc is broken. This issue still 
> persists for all Java files referred from scala doc.
> The relative path expression "€\{FILE_PATH}.scala" in 
> [https://github.com/apache/spark/blob/master/project/SparkBuild.scala] has 
> ".scala" hardcoded in the end. 
> If I try to access the source link on 
> [https://spark.apache.org/docs/2.4.4/api/scala/index.html#org.apache.spark.sql.sources.v2.DataSourceOptions],
>  it tries to take me to 
> [https://github.com/apache/spark/tree/v2.4.4/sql/core/src/main/java/org/apache/spark/sql/sources/v2/DataSourceOptions.java.scala]
> This is coming from /project/SparkBuild.scala :
> Line # 720
> {code:scala}
> // Use GitHub repository for Scaladoc source links
> unidocSourceBase := s"https://github.com/apache/spark/tree/v${version.value}";,
> scalacOptions in (ScalaUnidoc, unidoc) ++= Seq(
> "-groups", // Group similar methods together based on the @group annotation.
> "-skip-packages", "org.apache.hadoop"
> ) ++ (
> // Add links to sources when generating Scaladoc for a non-snapshot release
> if (!isSnapshot.value) {
> Opts.doc.sourceUrl(unidocSourceBase.value + "€{FILE_PATH}.scala")
> } else {
> Seq()
> }
> ){code}
>  



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscr...@spark.apache.org
For additional commands, e-mail: issues-h...@spark.apache.org

Reply via email to