adoxa/ansicon

Ansicon 1.86 causes bash to fail to launch

Closed this issue · 13 comments

Running Windows 10 1809.

Launching bash from cmd prevents it from launching. Launching bash.exe directly works just fine, so it must be something within Ansicon.

---------------------------
bash.exe - Application Error
---------------------------
The application was unable to start correctly (0xc0000142). Click OK to close the application. 
---------------------------
OK   
---------------------------
adoxa commented

Which bash? I'm a little out of date, but on 1803, cygwin (32- & 64-bit), MSYS, MSYS2 (64-bit) and git (64-bit) all worked.

adoxa commented

If it's WSL I don't think I can be of much help. Since you don't need ANSICON in that case anyway, a simple exclusion should help: set ANSICON_EXC=bash.

It's not in WSL afaik. It's just that something in ansicon running in cmd that prevents the bash launcher (C:\Windows\System32\bash.exe) from starting.

adoxa commented

I installed WSL in 1803 and that gave me bash.exe. However, it still worked with ANSICON:

Microsoft Windows [Version 10.0.17134.165]
(c) 2018 Microsoft Corporation. All rights reserved.

C:\Users\Jason>bash
Windows Subsystem for Linux has no installed distributions.
Distributions can be installed by visiting the Microsoft Store:
https://aka.ms/wslstore
Press any key to continue...

C:\Users\Jason>ansicon --version
ANSICON (64-bit) version 1.86 (4 November, 2018).

C:\Users\Jason>ansicon bash
Windows Subsystem for Linux has no installed distributions.
[...]

C:\Users\Jason>ansicon -p

C:\Users\Jason>bash
Windows Subsystem for Linux has no installed distributions.
[...]

That could mean: I'm not testing it right; it started with 1809; it needs a distribution; or there's something about your system. I was going to skip 1809, but might have to get it after all (it'll still be a few weeks before I do, though).

Still broken in 1809, will likely remove ansicon until this is fixed.

adoxa commented

Did you try the exclusion?

What exclusion?

tztztztz .... @rctgamer3
did you not really read what @adoxa wrote.. ?
#125 (comment)

Oh, yeah. I saw that, but forgot about it. Though that's a workaround and defeats the purpose of the bug, which is to fix an incompatibility with Windows 1809, the wsl launcher and ansicon.

adoxa commented

I couldn't reproduce the problem with 1803, I won't now be getting 1809, so it'll have to wait until 1903. What's wrong with using the workaround that was anticipated for just this type of problem?

This was fixed in v1.8.7. Bash failing to start likely was a side effect of the ansicon hooking bug crash that was fixed.

@rctgamer3 then could you add an other comment
and before you press the button, comment,
hold a second and press the other button "close&comment" for close the issue .
thank you and best regards
Blacky

adoxa commented

Oh, I didn't think this would fix it (7 gave me a different error), which is why I never mentioned it. That's one less thing to worry about.