LorrensP-2158466 opened a new issue, #10571:
URL: https://github.com/apache/datafusion/issues/10571

   ### 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 `Result`s
   
   
   ### Describe the solution you'd like
   
   _No response_
   
   ### Describe alternatives you've considered
   
   _No response_
   
   ### Additional context
   
   _No response_


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscr...@datafusion.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: github-unsubscr...@datafusion.apache.org
For additional commands, e-mail: github-h...@datafusion.apache.org

Reply via email to