# git bash bug

3 messages from 2025-07-09 to 2025-07-11. Participants: Preston, David J., brian m. carlson, Johannes Schindelin.
Thread: https://gitlist.dev/t/63772

## Preston, David J., 2025-07-09 17:20

Subject: git bash bug
Message-ID: <PH7PR11MB65466DEE20BA470C600C7B9B9549A@PH7PR11MB6546.namprd11.prod.outlook.com>
URL: https://gitlist.dev/e/PH7PR11MB65466DEE20BA470C600C7B9B9549A%40PH7PR11MB6546.namprd11.prod.outlook.com

```
Bug report attached.


Thank you for filling out a Git bug report!
Please answer the following questions to help us understand your issue.

What did you do before the bug happened? (Steps to reproduce your issue)
started happening after an update to a newer version of git... has been happening for a while, so i am not sure what version it started with

What did you expect to happen? (Expected behavior)
when using git bash in windows environment, when a previously typed command is executing and i start typing, i expect that what i type will eventually show up on the command line, in the order i typed it, once the executing command completes.

What happened instead? (Actual behavior)
letters that i have typed show up in a different order than i typed them.  basically, i think there is some async processing going on, and keyboard input is being handled in such a way that the keystrokes are output to the console in an order that is random based on race conditions in the async code.

What's different between what you expected and what actually happened?
keys output in a different order than i typed them in.

Anything else you want to add:

Please review the rest of the bug report below.
You can delete any lines you don't wish to share.


[System Info]
git version:
git version 2.49.0.windows.1
cpu: x86_64
built from commit: cca1f38702730b35f52c29efd62864b85e85ddcc
sizeof-long: 4
sizeof-size_t: 8
shell-path: D:/git-sdk-64-build-installers/usr/bin/sh
feature: fsmonitor--daemon
libcurl: 8.12.1
OpenSSL: OpenSSL 3.2.4 11 Feb 2025
zlib: 1.3.1
uname: Windows 10.0 22631 
compiler info: gnuc: 14.2
libc info: no libc information available
$SHELL (typically, interactive shell): C:\Program Files\Git\usr\bin\bash.exe


[Enabled Hooks]

```

## brian m. carlson, 2025-07-09 22:47

Subject: Re: git bash bug
Message-ID: <aG7xbbPf2ZsTh1ND@fruit.crustytoothpaste.net>
URL: https://gitlist.dev/e/aG7xbbPf2ZsTh1ND%40fruit.crustytoothpaste.net
In-Reply-To: <PH7PR11MB65466DEE20BA470C600C7B9B9549A@PH7PR11MB6546.namprd11.prod.outlook.com>

```
On 2025-07-09 at 17:20:22, Preston, David J. wrote:

Hi,

> Thank you for filling out a Git bug report!
> Please answer the following questions to help us understand your issue.
> 
> What did you do before the bug happened? (Steps to reproduce your issue)
> started happening after an update to a newer version of git... has been happening for a while, so i am not sure what version it started with
> 
> What did you expect to happen? (Expected behavior)
> when using git bash in windows environment, when a previously typed command is executing and i start typing, i expect that what i type will eventually show up on the command line, in the order i typed it, once the executing command completes.

The Git project doesn't ship bash, a terminal, or any software other
than the source code to Git.  Git Bash is part of Git for Windows, which
is a separate project.  You may want to report this https://github.com/git-for-windows/git/issues.

I would recommend searching for any relevant issues, open or closed,
first and providing any information that might be relevant.  For
instance, does this problem only occur when the system is loaded or does
it happen all the time, even with little load?  Is there anything else
going on that is correlated with the problem (e.g., a virus scan)?  Does
the same thing happen when running Git for Windows's bash through
Windows Terminal, or is it only the built-in MinTTY?  Those kinds of
things might help the maintainer solve the problem more quickly.

Best of luck on this.
-- 
brian m. carlson (they/them)
Toronto, Ontario, CA

```

## Johannes Schindelin, 2025-07-11 14:40

Subject: Re: git bash bug
Message-ID: <a8cfe8ee-81ab-b0e6-a82b-f8cbeb0d9122@gmx.de>
URL: https://gitlist.dev/e/a8cfe8ee-81ab-b0e6-a82b-f8cbeb0d9122%40gmx.de
In-Reply-To: <PH7PR11MB65466DEE20BA470C600C7B9B9549A@PH7PR11MB6546.namprd11.prod.outlook.com>

```
Hi David,

On Wed, 9 Jul 2025, Preston, David J. wrote:

> What did you do before the bug happened? (Steps to reproduce your issue)
> started happening after an update to a newer version of git... has been
> happening for a while, so i am not sure what version it started with
>
> What did you expect to happen? (Expected behavior)
> when using git bash in windows environment, when a previously typed
> command is executing and i start typing, i expect that what i type will
> eventually show up on the command line, in the order i typed it, once
> the executing command completes.
>
> What happened instead? (Actual behavior)
> letters that i have typed show up in a different order than i typed
> them.  basically, i think there is some async processing going on, and
> keyboard input is being handled in such a way that the keystrokes are
> output to the console in an order that is random based on race
> conditions in the async code.
>
> What's different between what you expected and what actually happened?
> keys output in a different order than i typed them in.

This is essentially the same issue that has been reported at
https://github.com/git-for-windows/git/issues/5632.

The problem is in the MSYS2 runtime, which is the POSIX emulation layer
required to run Bash that Git for Windows employed, which in turn is a
friendly fork of the Cygwin runtime.

I haven't had time to report this bug over in Cygwin yet (for which I
would have to verify that this bug reproduces with their own Bash running
in their own MinTTY). Maybe you can help out and install Cygwin
(https://cygwin.com) and perform that test?

Thanks,
Johannes

```
