I have application that has embedded IronPython and uses it to execute scripts that users write. When only my application is installed everything works as expected. I have embedded IronPython 2.7.4 dlls (my exe and IronPython dlls are in same folder after installation).
However, on some client machines there is IronPython 2.7.2 installed. It installs its dlls into GAC and my application ends up using them, instead of dlls that I shipped with application and application. This causes my application to fail, since I use property that is not available in 2.7.2.
Problem is that .NET sees these assemblies as having the same version (2.7.0.40) for some reason. As you can see in image below / file versions are different:
Right one is the one I ship with my application and left one is one that comes with IronPython 2.7.2. I do not register anything to GAC, but this it what is registered in GAC (IronPython installation added it):
C:\ $ gacutil /l | findstr IronPython
IronPython, Version=2.7.0.40, Culture=neutral, PublicKeyToken=7f709c5b713576e1, processorArchitecture=MSIL
IronPython.Modules, Version=2.7.0.40, Culture=neutral, PublicKeyToken=7f709c5b713576e1, processorArchitecture=MSIL
As you can see, they are registerd for version 2.7.0.40.
My question is - how can I force my application to use 2.7.4.1000 version of IronPython assemblies and not 2.7.2.1001 that is registered in GAC? Why is .NET ignoring third component of version number and can it be changed?
Edit:
If it is important, with IronPython 2.7.2 installed, my program fails with following error:
Unhandled Exception: System.MissingMethodException: Method not found: 'Boolean IronPython.Hosting.PythonConsoleOptions.get_BasicConsole()'.