Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Audit][SPARK-44838][SQL] raise_error improvement #10107

Open
amahussein opened this issue Dec 28, 2023 · 3 comments
Open

[Audit][SPARK-44838][SQL] raise_error improvement #10107

amahussein opened this issue Dec 28, 2023 · 3 comments
Labels
audit_4.0.0 Audit related tasks for 4.0.0 bug Something isn't working

Comments

@amahussein
Copy link
Collaborator

amahussein commented Dec 28, 2023

Describe the bug
Extend the raise_error() function to a two-argument version:

raise_error(errorClassStr, errorParamMap)

Examples

SELECT raise_error('VIEW_NOT_FOUND', map('relationName', '`v1`');
  [VIEW_NOT_FOUND] The view `v1` cannot be found. Verify the spelling
  • The single-parameter raise_error(str) will raise USER_RAISED_EXCEPTION
  • spark.sql.legacy.raiseErrorWithoutErrorClass (default: false) to revert to the old behavior for the single-parameter version.
  • assert_true() will also return USER_RAISED_EXCEPTION.

Additional context
https://issues.apache.org/jira/browse/SPARK-44838
apache/spark@9109d7037f4

@amahussein amahussein added bug Something isn't working ? - Needs Triage Need team to review and classify audit_4.0.0 Audit related tasks for 4.0.0 labels Dec 28, 2023
@revans2
Copy link
Collaborator

revans2 commented Dec 28, 2023

We don't support raise_error or RaiseError yet. We have not seen any customers using it so there has been no push to implement it. Even then it would probably just be a copy of the CPU version as there is nothing that we can do on the GPU with it.

@mattahrens mattahrens removed the ? - Needs Triage Need team to review and classify label Jan 2, 2024
@mattahrens mattahrens closed this as not planned Won't fix, can't repro, duplicate, stale Jan 2, 2024
@revans2
Copy link
Collaborator

revans2 commented Jan 3, 2024

I was wrong and this is in fact supported by us, so we need to make corresponding changes. We might need to make some changes to the UDF transpiler because this was added to support that.

@revans2 revans2 reopened this Jan 3, 2024
@revans2 revans2 added the ? - Needs Triage Need team to review and classify label Jan 3, 2024
@mattahrens mattahrens removed the ? - Needs Triage Need team to review and classify label Jan 9, 2024
@mythrocks
Copy link
Collaborator

so we need to make corresponding changes.

Unless I'm mistaken, #10969 is a dupe of this issue. Both seem to highlight the need for a shimmed GpuRaiseError.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
audit_4.0.0 Audit related tasks for 4.0.0 bug Something isn't working
Projects
None yet
Development

No branches or pull requests

4 participants