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

When an RDD has no partition, Python sum will throw "Can not reduce() empty RDD"

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 1.2.0
    • Fix Version/s: 1.4.1, 1.5.0
    • Component/s: PySpark
    • Labels:
      None

      Description

      The issue is because "sum" uses "reduce". Replacing it with "fold" will fix it.

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                zsxwing Shixiong Zhu
                Reporter:
                zsxwing Shixiong Zhu
              • Votes:
                0 Vote for this issue
                Watchers:
                2 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: