andygrove commented on code in PR #1821: URL: https://github.com/apache/datafusion-comet/pull/1821#discussion_r2116291551
########## native/core/src/execution/planner.rs: ########## @@ -146,15 +146,7 @@ pub struct PhysicalPlanner { impl Default for PhysicalPlanner { fn default() -> Self { - let session_ctx = Arc::new(SessionContext::new()); - - // register UDFs from datafusion-spark crate - session_ctx.register_udf(ScalarUDF::new_from_impl(SparkExpm1::default())); - - Self { - exec_context_id: TEST_EXEC_CONTEXT_ID, - session_ctx, - } + Self::new(Arc::new(SessionContext::new())) Review Comment: Note that `Self::new` will register the UDF: ```rust pub fn new(session_ctx: Arc<SessionContext>) -> Self { // register UDFs from datafusion-spark crate session_ctx.register_udf(ScalarUDF::new_from_impl(SparkExpm1::default())); Self { exec_context_id: TEST_EXEC_CONTEXT_ID, session_ctx, } } ``` -- 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 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