Fix variant_throw_on_type_mismatch/dynamic_throw_on_type_mismatch=false not catching exceptions during function execution#105543
Open
Avogar wants to merge 1 commit into
Open
Conversation
…ring `execute` The `try_build` lambda in `FunctionVariantAdaptor` and `FunctionDynamicAdaptor` only wrapped `build()` in a try-catch for type-related errors. Some functions (e.g. comparison functions like `equals`) pass `build()` successfully but throw `NO_COMMON_TYPE` during `execute()` because `executeGeneric` calls `getLeastSupertype` which rejects incompatible types like `String` and `UInt8`. Add a `try_execute` helper that wraps `execute()` calls with the same try-catch pattern, returning NULL for incompatible-type rows when `throw_on_type_mismatch` is disabled. Apply the fix to all three execution paths in both adaptors (single variant no NULLs, single variant with NULLs, and the general multi-variant case). Closes #103484 Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Contributor
|
Workflow [PR], commit [ea4ea81] Summary: ❌
AI ReviewSummaryThis PR fixes Final VerdictStatus: ✅ Approve |
Contributor
LLVM Coverage Report
Changed lines: 88.00% (66/75) · Uncovered code |
alexbakharew
approved these changes
May 28, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #103484
Changelog category (leave one):
Changelog entry (a user-readable short description of the changes that goes into CHANGELOG.md):
Fix
variant_throw_on_type_mismatch/dynamic_throw_on_type_mismatch=falsenot catching exceptions during function execution. Closes #103484