You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@datafusion.apache.org by gi...@apache.org on 2026/04/27 14:17:36 UTC
(datafusion) branch gh-readonly-queue/main/pr-21858-4e71785b881b329e437ad0397882d0c86bd7edc6 created (now d1939624b1)
This is an automated email from the ASF dual-hosted git repository.
github-merge-queue[bot] pushed a change to branch gh-readonly-queue/main/pr-21858-4e71785b881b329e437ad0397882d0c86bd7edc6
in repository https://gitbox.apache.org/repos/asf/datafusion.git
at d1939624b1 fix: Do not highlight the CLI hint directly (#21858)
This branch includes the following new commits:
new d1939624b1 fix: Do not highlight the CLI hint directly (#21858)
The 1 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails. The revisions
listed as "add" were already present in the repository and have only
been added to this reference.
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@datafusion.apache.org
For additional commands, e-mail: commits-help@datafusion.apache.org
(datafusion) 01/01: fix: Do not highlight the CLI hint directly (#21858)
Posted by gi...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
github-merge-queue[bot] pushed a commit to branch gh-readonly-queue/main/pr-21858-4e71785b881b329e437ad0397882d0c86bd7edc6
in repository https://gitbox.apache.org/repos/asf/datafusion.git
commit d1939624b12c0be9d68ade77a1643c5026efed52
Author: Nuno Faria <nu...@gmail.com>
AuthorDate: Mon Apr 27 15:17:11 2026 +0100
fix: Do not highlight the CLI hint directly (#21858)
## Which issue does this PR close?
- Closes #21574.
## Rationale for this change
Previously, the CLI hint was being highlighted directly, which was
causing an assertion to fail in `rustyline`.
## What changes are included in this PR?
- Use `highlight_hint` instead of manually highlighting the text.
## Are these changes tested?
Manually.
## Are there any user-facing changes?
No.
---
datafusion-cli/src/helper.rs | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/datafusion-cli/src/helper.rs b/datafusion-cli/src/helper.rs
index f01d0891b9..67e203cf79 100644
--- a/datafusion-cli/src/helper.rs
+++ b/datafusion-cli/src/helper.rs
@@ -124,6 +124,10 @@ impl Highlighter for CliHelper {
fn highlight_char(&self, line: &str, pos: usize, kind: CmdKind) -> bool {
self.highlighter.highlight_char(line, pos, kind)
}
+
+ fn highlight_hint<'h>(&self, hint: &'h str) -> Cow<'h, str> {
+ Color::gray(hint).into()
+ }
}
impl Hinter for CliHelper {
@@ -134,7 +138,7 @@ impl Hinter for CliHelper {
self.show_hint.set(false);
}
(self.show_hint.get() && line.trim().is_empty())
- .then(|| Color::gray(DEFAULT_HINT_SUGGESTION))
+ .then(|| DEFAULT_HINT_SUGGESTION.to_owned())
}
}
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@datafusion.apache.org
For additional commands, e-mail: commits-help@datafusion.apache.org