Hi,
In Insight.Database.Schema.SchemaInstaller context.DropObjects.Sort((e1, e2) => -CompareByInstallOrder(e1, e2)); is done too early. Right now the DropObjects are sorted, and in the codeblock for anything that's not entirely new the DropObject collection can be modified, resulting in a possible incorrect sortorder.
Solution is to place the DropObject.Sort on a line following the code block for anything that's not entirely new; right next to the sort of the AddObject will do just fine.
Thx,
Jeroen