KassaSana commented on code in PR #25807:
URL: https://github.com/apache/datafusion/pull/25807#discussion_r4394652093
##########
datafusion-cli/src/exec.rs:
##########
@@ -126,13 +126,24 @@ pub async fn exec_from_repl(
print_options: &mut PrintOptions,
) -> rustyline::Result<()> {
let mut rl = Editor::new()?;
- rl.set_helper(Some(CliHelper::new(
- &ctx.task_ctx().session_config().options().sql_parser.dialect,
- print_options.color,
- )));
+ {
+ let task_ctx = ctx.task_ctx();
Review Comment:
Thanks! Done in 7a6e21d. I replaced `set_recursion_limit` with
`CliHelper::set_parser_options(&SqlParserOptions)`, which sets both dialect and
recursion limit, so the REPL loop now syncs with a single call. The extra setup
block before the loop is gone (back to the original `CliHelper::new`), since
the loop syncs before the first read anyway. `exec_and_print` still reads the
options once to build the parser.
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]