Skip to content

ConvertDBForHistoricalConfigurations fails: could not load MOE.Common, an attempt was made to load a program with an incorrect format #222

Description

@dbrandesky

I'm attempting to upgrade a 4.2.4 system to 4.3.1, but I can't get past the first step. ConvertDBForHistoricalConfigurations.exe is failing because of a System.BadImageFormatException. I experienced something similar to this with the website when I first launched it, then found I had to enable 32-bit support in the application pools in IIS. This fixed the website, but I don't know of an equivalent for this standalone exe.

System information:

  • Server: Windows 2016 x64
  • MS SQL: Express 2019
  • Current ATSPM Version: 4.2.4

Full error message:

C:\Users\Administrator\Downloads\ATSPM.Executables_4.3.1\ATSPM Executables\ConvertDBForHistoricalConfigurations\bin\Release>ConvertDBForHistoricalConfigurations.exe

Unhandled Exception: System.BadImageFormatException: Could not load file or assembly 'MOE.Common, Version=2.16.0.0, Culture=neutral, PublicKeyToken=null' or one of its dependencies. An attempt was made to load a program with an incorrect format.
   at ConvertDBForHistoricalConfigurations.Program.RunMigrations()
   at ConvertDBForHistoricalConfigurations.Program.Main() in C:\Temp\projects\avenue\ATSPM\ConvertDBForHistoricalConfigurations\Program.cs:line 53

Looking at the source, line 53 is where RunMigrations() is called, which seems to be the primary function that calls other functions in the script.

Activity

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions