Skip to content

Ctrl+G (edit in $EDITOR) breaks ask_user question mode (regression of #4230) #5004

Description

@yurymann

Describe the bug

Regression of #4230 (closed as completed 2026-07-30).

When Copilot asks a question during planning (plan mode) and I select the last option to enter free text, pressing Ctrl+G — the "edit prompt in $EDITOR" shortcut that works for a normal prompt — exits question mode instead of opening my editor. It is not clear whether an answer was accepted or the question was abandoned; the session state afterward is ambiguous.

Under the hood the keypress is registered as a cancel of the elicitation. In a session where this reproduced, the tool call telemetry shows the freeform ask_user question completing with elicitation_action: "cancel" and result "User cancelled the request." — i.e. Ctrl+G silently cancels the question rather than round-tripping the answer through $EDITOR.

Previously fixed under #4230, but the behavior is back (or a closely related regression).

Affected version

GitHub Copilot CLI 1.0.89

Steps to reproduce the behavior

  1. Start in plan mode (or any flow where Copilot calls a question/elicitation).
  2. Trigger a question that offers a freeform "type your own answer" option (e.g. a text field).
  3. Select that option and start typing an answer.
  4. Press Ctrl+G (the normal "edit prompt in $EDITOR" shortcut).

Result: Question prompt is torn down. No editor opens with the freeform answer, and there is no clear accepted/abandoned signal. Internally the elicitation completes with elicitation_action: "cancel" (result: "User cancelled the request.").

Expected behavior

Ctrl+G should open the current freeform answer in $EDITOR and, on save, return the edited text to the question's freeform field while staying in question mode — the same round-trip behavior it has for a normal prompt.

Alternatively, if Ctrl+G is not supported in that context, it should be disabled there with a clear message instead of silently cancelling the question.

Additional context

  • Regression of Ctrl+G (edit in $EDITOR) breaks ask_user question mode #4230 "Ctrl+G (edit in $EDITOR) breaks ask_user question mode" (closed as completed).
  • OS: Linux (WSL).
  • Reproduced in plan mode with model gpt-5.6-sol; the question was a freeform multi-field ask_user elicitation.
  • Session telemetry for the cancelled elicitation: elicitation_action: "cancel", elicitation_field_types: ["string"], result "User cancelled the request."

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    area:input-keyboardKeyboard shortcuts, keybindings, copy/paste, clipboard, mouse, and text input

    Type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions