Uploaded image for project: 'Spark'
  1. Spark
  2. SPARK-16153

A single-line ScalaDoc and @deprecate annotation would break genjavadoc

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 2.0.0
    • Fix Version/s: 2.0.0
    • Component/s: Documentation
    • Labels:
      None

      Description

      Env: Scala 2.11.8, Java 1.7.0_79

      We recently deprecated setLabelCol in ChiSqSelectorModel:

        /** @group setParam */
        @Since("1.6.0")
        @deprecated("labelCol is not used by ChiSqSelectorModel.", "2.0.0")
        def setLabelCol(value: String): this.type = set(labelCol, value)
      

      This unfortunately hit a genjavadoc bug and broken doc generation. This is the generated Java code:

        /** @group setParam */
        public  org.apache.spark.ml.feature.ChiSqSelectorModel setOutputCol (java.lang.String value)  { throw new RuntimeException(); }
         *
         * @deprecated labelCol is not used by ChiSqSelectorModel. Since 2.0.0.
        */
        public  org.apache.spark.ml.feature.ChiSqSelectorModel setLabelCol (java.lang.String value)  { throw new RuntimeException(); }
      

      Switching to multiline is a workaround. Reported the bug to genjavadoc at https://github.com/typesafehub/genjavadoc/issues/85.

        Attachments

          Activity

            People

            • Assignee:
              mengxr Xiangrui Meng
              Reporter:
              mengxr Xiangrui Meng
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: