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

raise_error should only take the error class parameter for internal usage

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • 4.0.0
    • 4.0.0
    • SQL

    Description

      In https://github.com/apache/spark/pull/42985 , we extended the `raise_error` function to take an extra error-class parameter. However, this is too powerful as users may use it to throw special internal errors that we don't expect them to throw.

      It's useful to have this `raise_error` extension for internal usage. We should create an `ExpressionBuilder` for `raise_error` function, so that we only allow end users to pass the error message, not error class.

      Attachments

        Issue Links

          Activity

            People

              dbatomic Aleksandar Tomic
              cloud_fan Wenchen Fan
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: