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

Loosen the newline assert condition on 'examples' field in ExpressionInfo

    XMLWordPrintableJSON

    Details

    • Type: Improvement
    • Status: Resolved
    • Priority: Trivial
    • Resolution: Fixed
    • Affects Version/s: 2.4.1, 3.0.0
    • Fix Version/s: 2.4.2, 3.0.0
    • Component/s: SQL
    • Labels:
      None

      Description

      I haven't tested by myself on Windows and I am not 100% sure if this is going to cause an actual problem.

      The codes here:

              assert examples.isEmpty() || examples.startsWith(System.lineSeparator() + "    Examples:");
      

      Given my speculation, if Spark is built in Linux, and it's executed on Windows, it looks possible to throw an exception because encoded newline in the binary is \n but System.lineSeparator returns \r\n.

      I haven't tested it by myself but I think it's better to loosen the condition and forget about this problem.

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                hyukjin.kwon Hyukjin Kwon
                Reporter:
                hyukjin.kwon Hyukjin Kwon
              • Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: