Skip to content

Conversation

richardc-db
Copy link
Contributor

@richardc-db richardc-db commented Oct 6, 2025

What changes were proposed in this pull request?

also catch IllegalArgumentException for AES encrypt/decrypt expressions

Why are the changes needed?

previously, if empty input is given to AES decrypt, it would return the error

IllegalArgumentException: Invalid buffer arguments

Now, with this change,

SparkRuntimeException: [INVALID_PARAMETER_VALUE.AES_KEY] The value of parameter(s) `expr`, `key` in `aes_encrypt`/`aes_decrypt` is invalid: detail message: Invalid buffer arguments

Does this PR introduce any user-facing change?

yes - see above. Error message change

How was this patch tested?

added UT

Was this patch authored or co-authored using generative AI tooling?

no

@github-actions github-actions bot added the SQL label Oct 6, 2025
@richardc-db richardc-db changed the title [CATALYST][SQL] Allow empty input on AES decrypt to have error class [SPARK-53806][SQL] Allow empty input on AES decrypt to have error class Oct 6, 2025
Copy link
Member

@dongjoon-hyun dongjoon-hyun left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

+1, LGTM. Thank you, @richardc-db .

Merged to master for Apache Spark 4.1.0-preview3.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants