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

Attach diagnostic for wrong arg number error #15451

Open
wants to merge 4 commits into
base: main
Choose a base branch
from

Conversation

Chen-Yuan-Lai
Copy link
Contributor

Which issue does this PR close?

Rationale for this change

well explained in the issue.

What changes are included in this PR?

  1. Create a new function take_function_args_with_diag, which can accept span info and rerun DataFusionError::Diagnostic.
  2. To prevent diagnostic info loss because the error macros "flatten" the inner error to a string, diagnostic was cloned and reattached to a new error in different layers
  3. Add a new test

Are these changes tested?

Are there any user-facing changes?

@github-actions github-actions bot added sql SQL Planner logical-expr Logical plan and expressions common Related to common crate functions Changes to functions implementation labels Mar 27, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
common Related to common crate functions Changes to functions implementation logical-expr Logical plan and expressions sql SQL Planner
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Attach Diagnostic to "wrong number of arguments" error
1 participant