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

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

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Resolved
    • Trivial
    • Resolution: Fixed
    • 2.4.1, 3.0.0
    • 2.4.2, 3.0.0
    • SQL
    • 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

              gurwls223 Hyukjin Kwon
              gurwls223 Hyukjin Kwon
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: