You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is your feature request related to a problem or challenge?
This is really a feature request but more of a question.
Currently UserDefinedLogicalNode::from_template only returns Arc<dyn Self> but i have noticed that LogicalPlan::with_new_exprs does return a Result. So when it calls from_template on an Extension node, it just wraps it in an Ok().
In the example of UserDefinedLogicalNodeCore where TopK is implemented, the implementation of from_template first asserts the inputs and exprs.
I have also tried to implement a custom LogicalPlan node and my own implementation of from_template also has several error cases (not just asserting the new values) which i unfortunately have to unwrap.
Is this expected behaviour, or is it maybe nicer to return Results
Describe the solution you'd like
No response
Describe alternatives you've considered
No response
Additional context
No response
The text was updated successfully, but these errors were encountered:
(BTW if anyone wants a workaround for this in older versions that does not requier a panic, they could potentially return a node that would generate a runtime error if the arguments to from_template didn't error)
Is your feature request related to a problem or challenge?
This is really a feature request but more of a question.
Currently
UserDefinedLogicalNode::from_template
only returnsArc<dyn Self>
but i have noticed thatLogicalPlan::with_new_exprs
does return a Result. So when it callsfrom_template
on an Extension node, it just wraps it in anOk()
.In the example of
UserDefinedLogicalNodeCore
where TopK is implemented, the implementation offrom_template
first asserts the inputs and exprs.I have also tried to implement a custom LogicalPlan node and my own implementation of
from_template
also has several error cases (not just asserting the new values) which i unfortunately have to unwrap.Is this expected behaviour, or is it maybe nicer to return
Result
sDescribe the solution you'd like
No response
Describe alternatives you've considered
No response
Additional context
No response
The text was updated successfully, but these errors were encountered: