Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cli/sql: the bufio editor does not support cancelling input with ctrl+c #93053

Open
knz opened this issue Dec 5, 2022 · 0 comments
Open

cli/sql: the bufio editor does not support cancelling input with ctrl+c #93053

knz opened this issue Dec 5, 2022 · 0 comments
Labels
C-bug Code not up to spec/doc, specs & docs deemed correct. Solution expected to change code/behavior.

Comments

@knz
Copy link
Contributor

knz commented Dec 5, 2022

Describe the problem

When using --no-line-editor, pressing ctrl+d to send EOF works, but ctrl+C does not do anything.
Instead the input displays ^C and nothing happens.

Expected behavior

Ctrl+c should interrupt the current input.

This could be implemented using e.g. https://github.com/muesli/cancelreader.

Jira issue: CRDB-22137

Epic CRDB-23743

@knz knz added the C-bug Code not up to spec/doc, specs & docs deemed correct. Solution expected to change code/behavior. label Dec 5, 2022
knz added a commit to knz/cockroach that referenced this issue Dec 5, 2022
When in COPY mode, multi-line input is disabled and the tab key inputs
raw ASCII TAB characters.

This commit achieves this by redirecting the input to either the
interactive editor or the bufio-based editor, depending on whether
the current mode is COPY.

NB: using ctrl+c while in COPY mode will not work with this patch, but
that is caused by a separate issue cockroachdb#93053 and the behavior will be
restored when that separate issue is fixed. In the meantime the user
can use `\.` or ctrl+d to terminate their input.

Release note: None
knz added a commit to knz/cockroach that referenced this issue Dec 6, 2022
When in COPY mode, multi-line input is disabled and the tab key inputs
raw ASCII TAB characters.

This commit achieves this by redirecting the input to either the
interactive editor or the bufio-based editor, depending on whether
the current mode is COPY.

NB: using ctrl+c while in COPY mode will not work with this patch, but
that is caused by a separate issue cockroachdb#93053 and the behavior will be
restored when that separate issue is fixed. In the meantime the user
can use `\.` or ctrl+d to terminate their input.

Release note: None
craig bot pushed a commit that referenced this issue Dec 6, 2022
93054: roachtest: add `failover/system-non-liveness` r=erikgrinaker a=erikgrinaker

This patch adds a roachtest measuring the pMax latency impact on user ranges when system range leaseholders fail (excluding the liveness range, which is tested individually in `failover/liveness`). Ideally, this should not affect user traffic at all, and the results confirm this.

Epic: none
Release note: None

93057: cli/sql: properly support special COPY input mode r=otan a=knz

Fixes #93031.

When in COPY mode, multi-line input is disabled and the tab key inputs raw ASCII TAB characters.

This commit achieves this by redirecting the input to either the interactive editor or the bufio-based editor, depending on whether the current mode is COPY.

NB: using ctrl+c while in COPY mode will not work with this patch, but that is caused by a separate issue #93053 and the behavior will be restored when that separate issue is fixed. In the meantime the user can use `\.` or ctrl+d to terminate their input.

Release note: None

93081: ui: prevent additional RPC fanout in insights api r=xinhaoz a=xinhaoz

Previously the query used to fetch insights was triggering 2 cluster-wide RPC fanouts by doing a self-join on `crdb_internal.cluster_execution_insights`.
We should buffer the insights virtual table to prevent an additional fanout to construct the table again.

Epic: none

Release note: None

Co-authored-by: Erik Grinaker <[email protected]>
Co-authored-by: Raphael 'kena' Poss <[email protected]>
Co-authored-by: Xin Hao Zhang <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-bug Code not up to spec/doc, specs & docs deemed correct. Solution expected to change code/behavior.
Projects
None yet
Development

No branches or pull requests

1 participant