Skip to content

[Windows] CTRL_C_EVENT not handled by bun (umbrella issue) #7074

Closed

Description

@kommander

This is to collect issues that are reporting ANSI escape sequences after CTRL+C in some windows terminals and shell, where it sends a CTRL_C_EVENT which is not handled by bun.

Activity

  1. added
    opentuiThis relates to changes in v1.0, now that opencode uses opentui
    on Jan 6, 2026
  2. github-actions commented on Jan 6, 2026

    @github-actions
    Contributor

    This umbrella issue appropriately collects ANSI escape sequence issues related to CTRL_C handling. Additional related issues found:

    All of these appear to stem from improper CTRL_C_EVENT and signal handling on Windows. The umbrella issue structure is good for tracking the root cause.

  3. Hona commented on Jan 6, 2026

    @Hona
    Member

    on windows bun, the ctrl+c sigint gets sent to all process+childprocess, so the bun run wrapper instantly kills its child.
    i need to check what happens with the published app too...
    i have a bun wip branch that is a poc fixing this, but it janky.
    not sure its something opentui/opencode can handle as a workaround if its parent process is killing it

  4. val-2 commented on Jan 8, 2026

    @val-2
    Contributor

    Is this issue for collecting reports until the Bun team fixes it or are temporary workarounds in OpenCode also accepted?

  5. Hona commented on Jan 8, 2026

    @Hona
    Member

    I have submitted a PR to the Bun team resolving this for us

  6. Hona commented on Jan 8, 2026

    @Hona
    Member

    oven-sh/bun#25876

    I am seeing about adding tests.
    Also need to investigate the wider impact of this change.
    So there's more for me to do on this PR.
    Hoping for guidance from the Bun team tho.

  7. carljuneau commented on Jan 15, 2026

    @carljuneau

    oven-sh/bun#25876

    I am seeing about adding tests. Also need to investigate the wider impact of this change. So there's more for me to do on this PR. Hoping for guidance from the Bun team tho.

    Thanks for doing this! I press Ctrl+C out of habit and get kicked out 4-5x a day. Ugh.

  8. tnglemongrass commented on Feb 5, 2026

    @tnglemongrass

    Any progress on this?

    I noticed that it only appears after update check, and that autoupdate: false doesn't properly skip it currently.

    With that PR + autoupdate: false Ctrl+C just works as expected.

    I'd be happy if someone could look into it.

  9. Hona commented on Feb 6, 2026

    @Hona
    Member

    Yes, early next week a beta build will be running a bun fork which fixes the root cause :)

  10. xiongxingplus commented on Feb 6, 2026

    @xiongxingplus

    Come on, boss!

  11. Hona commented on Feb 12, 2026

    @Hona
    Member

    ctrl+c handling is now in as of 1.1.60

  12. carljuneau commented on Feb 13, 2026

    @carljuneau

    Works for me now. Thanks!

  13. alMubarmij commented on Mar 6, 2026

    @alMubarmij

    ctrl+c handling is now in as of 1.1.60
    How?

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

Metadata

Metadata

Labels

bugSomething isn't workingopentuiThis relates to changes in v1.0, now that opencode uses opentuiwindows

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions