mercurialside-by-side

Mercurial side-by-side configuration is incorrect


I'm trying to install and run x64 Mercurial 3.8.3, but I'm getting the following error:

D:\Program Files\Mercurial>hg.exe
The application has failed to start because its side-by-side configuration is incorrect. Please see the application event log or use the command-line sxstrace.exe tool for more detail.

Running sxstrace.exe gives the following log:

=================
Begin Activation Context Generation.
Input Parameter:
    Flags = 0
    ProcessorArchitecture = AMD64
    CultureFallBacks = en-US;en
    ManifestPath = D:\Program Files\Mercurial\hg.exe
    AssemblyDirectory = D:\Program Files\Mercurial\
    Application Config File = 
-----------------
INFO: Parsing Manifest File D:\Program Files\Mercurial\hg.exe.
    INFO: Manifest Definition Identity is (null).
    INFO: Reference: Microsoft.VC90.CRT,processorArchitecture="amd64",publicKeyToken="1fc8b3b9a1e18e3b",type="win32",version="9.0.21022.8"
INFO: Resolving reference Microsoft.VC90.CRT,processorArchitecture="amd64",publicKeyToken="1fc8b3b9a1e18e3b",type="win32",version="9.0.21022.8".
    INFO: Resolving reference for ProcessorArchitecture amd64.
        INFO: Resolving reference for culture Neutral.
            INFO: Applying Binding Policy.
                INFO: Find publisher policy at C:\WINDOWS\WinSxS\manifests\amd64_policy.9.0.microsoft.vc90.crt_1fc8b3b9a1e18e3b_9.0.30729.9177_none_acd40623e1d81331.manifest
            INFO: Begin assembly probing.
            INFO: End assembly probing.
ERROR: Activation Context generation failed.
End Activation Context Generation.

It seems like it's looking for C:\WINDOWS\WinSxS\manifests\amd64_policy.9.0.microsoft.vc90.crt_1fc8b3b9a1e18e3b_9.0.30729.9177_none_acd40623e1d81331.manifest, which doesn't exist on my computer. I think this file comes from the Microsoft Visual C++ 2008 Redistributable Package (x64), but when I installed/repaired it I still get the same error.

I've also come across this same package from chocolatey, but its version history seems to indicate that its latest version is 9.0.30729.6161, not the 9.0.30729.9177 I'm looking for. I'm not sure where to find this version of the package.

I've already looked at these questions which seem very similar to my situation:

Edit: I've just reinstalled with x86 Mercurial and it works. Not ideal, but at least it's a workaround.


Solution

  • Microsoft Visual C++ 2008 Redistributable Package 9.0.30729.9177 doesn't seem to be publicly available, so I ended up reinstalling Windows. Now I can run Mercurial after installing it.