Rezoom.SQL icon indicating copy to clipboard operation
Rezoom.SQL copied to clipboard

Generated code doesn't work with LicenseToCIL 1.0.0

Open marklam opened this issue 7 years ago • 1 comments

Following the tutorial in a .net 4.7.2 console app with FSharp.Core 4.5, the generated code produces an exception

System.TypeInitializationException
  HResult=0x80131534
  Message=The type initializer for 'Rezoom.SQL.Mapping.CodeGeneration.ReaderTemplate`1' threw an exception.
  Source=Rezoom.SQL.Mapping
  StackTrace:
   at Rezoom.SQL.Mapping.CodeGeneration.ReaderTemplate`1.Template()
   at Rezoom.SQL.Compiler.BackendUtilities.DefaultMigrationBackend.GetMigrationsRun()
   at Rezoom.SQL.Migrations.MigrationUtilities.runMigrations(MigrationConfig config, IMigrationBackend backend, IEnumerable`1 migrationTrees)
   at Rezoom.SQL.Migrations.MigrationExtensions.Run(MigrationTree`1[] migrations, MigrationConfig config, FSharpFunc`2 backend)
   at Program.MyModel.Migrate(MigrationConfig config)
   at Program.migrate()
   at Program.main(String[] argv)

Inner Exception 1:
MissingMethodException: Method not found: 'Microsoft.FSharp.Core.FSharpFunc`2<S`1<!!0>,Microsoft.FSharp.Core.FSharpFunc`2<LicenseToCIL.IL,S`1<S`1<!!1>>>> LicenseToCIL.Ops.newobj'x(System.Reflection.ConstructorInfo)'.

It seems to be a problem with the LicenseToCIL dependency, because pinning at 0.3.0 fixes it.

marklam avatar Sep 17 '18 09:09 marklam

Same underlying issue as #37.

rspeele avatar Oct 02 '18 00:10 rspeele