[Bug] Ctrl+G with micro editor erases input text on exit

Resolved 💬 3 comments Opened Jan 19, 2026 by Surikesh Closed Jan 23, 2026

Bug Description
Bug: Ctrl+G with micro editor erases all input text

Environment:

  • macOS
  • Editor: micro
  • Terminal: [твой терминал, например iTerm2/Terminal.app/Wezterm]

Steps to reproduce:

  1. Start typing a prompt in Claude Code
  2. Press Ctrl+G to open external editor (micro)
  3. Make edits or just save without changes
  4. Exit micro (Ctrl+Q)

Expected: Edited text returns to Claude Code input
Actual: All previously typed text is erased, input buffer is empty

This makes Ctrl+G unusable with micro editor. Related to issues #11286, #16460.

Environment Info

  • Platform: darwin
  • Terminal: WezTerm
  • Version: 2.1.12
  • Feedback ID: d5efa054-42b0-4b7c-8966-5e20a3989c73

Errors

[{"error":"Error: read ECONNRESET\n    at B8A.from (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:26:8256)\n    at t$.<anonymous> (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:44:10016)\n    at t$.emit (node:events:519:35)\n    at t$.emit (node:domain:489:12)\n    at bw1.<computed> (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:43:1117)\n    at ClientRequest.emit (node:events:519:35)\n    at ClientRequest.emit (node:domain:489:12)\n    at emitErrorEvent (node:_http_client:104:11)\n    at TLSSocket.socketErrorListener (node:_http_client:518:5)\n    at TLSSocket.emit (node:events:507:28)\n    at v$A.request (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:46:2130)\n    at process.processTicksAndRejections (node:internal/process/task_queues:105:5)\n    at async vy0 (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:5371:4236)","timestamp":"2026-01-19T10:45:20.935Z"},{"error":"Error: read ECONNRESET\n    at B8A.from (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:26:8256)\n    at t$.<anonymous> (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:44:10016)\n    at t$.emit (node:events:519:35)\n    at t$.emit (node:domain:489:12)\n    at bw1.<computed> (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:43:1117)\n    at ClientRequest.emit (node:events:519:35)\n    at ClientRequest.emit (node:domain:489:12)\n    at emitErrorEvent (node:_http_client:104:11)\n    at TLSSocket.socketErrorListener (node:_http_client:518:5)\n    at TLSSocket.emit (node:events:507:28)\n    at v$A.request (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:46:2130)\n    at process.processTicksAndRejections (node:internal/process/task_queues:105:5)\n    at async vy0 (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:5371:4236)","timestamp":"2026-01-19T10:45:36.474Z"},{"error":"Error: read ECONNRESET\n    at B8A.from (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:26:8256)\n    at t$.<anonymous> (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:44:10016)\n    at t$.emit (node:events:519:35)\n    at t$.emit (node:domain:489:12)\n    at bw1.<computed> (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:43:1117)\n    at ClientRequest.emit (node:events:519:35)\n    at ClientRequest.emit (node:domain:489:12)\n    at emitErrorEvent (node:_http_client:104:11)\n    at TLSSocket.socketErrorListener (node:_http_client:518:5)\n    at TLSSocket.emit (node:events:507:28)\n    at v$A.request (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:46:2130)\n    at process.processTicksAndRejections (node:internal/process/task_queues:105:5)\n    at async vy0 (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:5371:4236)","timestamp":"2026-01-19T10:45:52.081Z"},{"error":"Error: read ECONNRESET\n    at B8A.from (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:26:8256)\n    at t$.<anonymous> (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:44:10016)\n    at t$.emit (node:events:519:35)\n    at t$.emit (node:domain:489:12)\n    at bw1.<computed> (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:43:1117)\n    at ClientRequest.emit (node:events:519:35)\n    at ClientRequest.emit (node:domain:489:12)\n    at emitErrorEvent (node:_http_client:104:11)\n    at TLSSocket.socketErrorListener (node:_http_client:518:5)\n    at TLSSocket.emit (node:events:507:28)\n    at v$A.request (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:46:2130)\n    at process.processTicksAndRejections (node:internal/process/task_queues:105:5)\n    at async vy0 (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:5371:4236)","timestamp":"2026-01-19T10:46:17.792Z"},{"error":"Error: read ECONNRESET\n    at B8A.from (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:26:8256)\n    at

Note: Error logs were truncated.

View original on GitHub ↗

This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗