Jump to content

Crashing on "Module Manager: Running post patch callbacks" and "Extraplanetary Launchpads Recipes" When Installed


Recommended Posts

Its' KolonyTools [Nope! See below, I forgot this line when I hit "Save"!]

AssemblyLoader: Exception loading 'KolonyTools': System.Reflection.ReflectionTypeLoadException: Exception of type 'System.Reflection.ReflectionTypeLoadException' was thrown.
  at (wrapper managed-to-native) System.Reflection.Assembly.GetTypes(System.Reflection.Assembly,bool)
  at System.Reflection.Assembly.GetTypes () [0x00000] in <ad04dee02e7e4a85a1299c7ee81c79f6>:0
  at AssemblyLoader.LoadAssemblies () [0x000e6] in <55ba45dc3a43403382024deac8dcd0be>:0

There're some of these exceptions on the log, usually meaning you forgot to install some dependency.

However, I also found:

TypeLoadException: Could not load type 'ModuleManager.CustomConfigsManager' from assembly 'ModuleManager, Version=4.1.3.0, Culture=neutral, PublicKeyToken=null'.
  at (wrapper managed-to-native) System.MonoCustomAttrs:GetCustomAttributesInternal (System.Reflection.ICustomAttributeProvider,System.Type,bool)
  at System.MonoCustomAttrs.GetCustomAttributesBase (ICustomAttributeProvider obj, System.Type attributeType) [0x00000] in <filename unknown>:0
  at System.MonoCustomAttrs.GetCustomAttributes (ICustomAttributeProvider obj, System.Type attributeType, Boolean inherit) [0x00000] in <filename unknown>:0
  at System.MonoType.GetCustomAttributes (System.Type attributeType, Boolean inherit) [0x00000] in <filename unknown>:0
  at UnityEngine.AttributeHelperEngine.GetParentTypeDisallowingMultipleInclusion (System.Type type) [0x00000] in <filename unknown>:0
UnityEngine.GameObject:Internal_AddComponentWithType(Type)
UnityEngine.GameObject:AddComponent(Type)
AddonLoader:StartAddon(LoadedAssembly, Type, KSPAddon, Startup)
AddonLoader:StartAddons(Startup)
AddonLoader:OnLevelLoaded(GameScenes)
AddonLoader:OnSceneLoaded(Scene, LoadSceneMode)
UnityEngine.SceneManagement.SceneManager:Internal_SceneLoaded(Scene, LoadSceneMode)

What appears to mean your installment is really botched!

And there're many, many, many exceptions scattered on the log.

And then I found this:

[KSP Version]: 1.7.3.2594 (WindowsPlayer x64) (x64) en-us ==============================

You probably installed KSP 1.7.3 by accident, and this explains the incredible avalanche of Exceptions everywhere - most Add'Ons nowadays are compiled on C# 4, and can be only used on KSP 1.8 and newer, and this includes Module Manager.

Since you thought you are on KSP 1.10.1, I think you had setup Steam to use KSP 1.7.3 on the Beta program and forgot about. Open your Steam Client, look for the KSP there, right click on it and opt out from the Beta program.

-- -- POST EDIT -- --

Better: select KSP 1.10.1 in the Beta Program, so you don't risk being (badly) surprised when KSP 1.10.2, I mean, KSP 1.11.0 is released!

Edited by Lisias
POST EDIT
Link to comment
Share on other sites

22 hours ago, Lisias said:

Its' KolonyTools [Nope! See below, I forgot this line when I hit "Save"!]


AssemblyLoader: Exception loading 'KolonyTools': System.Reflection.ReflectionTypeLoadException: Exception of type 'System.Reflection.ReflectionTypeLoadException' was thrown.
  at (wrapper managed-to-native) System.Reflection.Assembly.GetTypes(System.Reflection.Assembly,bool)
  at System.Reflection.Assembly.GetTypes () [0x00000] in <ad04dee02e7e4a85a1299c7ee81c79f6>:0
  at AssemblyLoader.LoadAssemblies () [0x000e6] in <55ba45dc3a43403382024deac8dcd0be>:0

There're some of these exceptions on the log, usually meaning you forgot to install some dependency.

However, I also found:


TypeLoadException: Could not load type 'ModuleManager.CustomConfigsManager' from assembly 'ModuleManager, Version=4.1.3.0, Culture=neutral, PublicKeyToken=null'.
  at (wrapper managed-to-native) System.MonoCustomAttrs:GetCustomAttributesInternal (System.Reflection.ICustomAttributeProvider,System.Type,bool)
  at System.MonoCustomAttrs.GetCustomAttributesBase (ICustomAttributeProvider obj, System.Type attributeType) [0x00000] in <filename unknown>:0
  at System.MonoCustomAttrs.GetCustomAttributes (ICustomAttributeProvider obj, System.Type attributeType, Boolean inherit) [0x00000] in <filename unknown>:0
  at System.MonoType.GetCustomAttributes (System.Type attributeType, Boolean inherit) [0x00000] in <filename unknown>:0
  at UnityEngine.AttributeHelperEngine.GetParentTypeDisallowingMultipleInclusion (System.Type type) [0x00000] in <filename unknown>:0
UnityEngine.GameObject:Internal_AddComponentWithType(Type)
UnityEngine.GameObject:AddComponent(Type)
AddonLoader:StartAddon(LoadedAssembly, Type, KSPAddon, Startup)
AddonLoader:StartAddons(Startup)
AddonLoader:OnLevelLoaded(GameScenes)
AddonLoader:OnSceneLoaded(Scene, LoadSceneMode)
UnityEngine.SceneManagement.SceneManager:Internal_SceneLoaded(Scene, LoadSceneMode)

What appears to mean your installment is really botched!

And there're many, many, many exceptions scattered on the log.

And then I found this:


[KSP Version]: 1.7.3.2594 (WindowsPlayer x64) (x64) en-us ==============================

You probably installed KSP 1.7.3 by accident, and this explains the incredible avalanche of Exceptions everywhere - most Add'Ons nowadays are compiled on C# 4, and can be only used on KSP 1.8 and newer, and this includes Module Manager.

Since you thought you are on KSP 1.10.1, I think you had setup Steam to use KSP 1.7.3 on the Beta program and forgot about. Open your Steam Client, look for the KSP there, right click on it and opt out from the Beta program.

-- -- POST EDIT -- --

Better: select KSP 1.10.1 in the Beta Program, so you don't risk being (badly) surprised when KSP 1.10.2, I mean, KSP 1.11.0 is released!

Thank you for the help, that's really interesting. I'm certain that I am on 1.10.1 now if I wasn't already and I'm still getting the same error. Crash on "Module Manager: Running Post Patch Callbacks. Here's some new logs:

https://www.dropbox.com/sh/jsh7cyny5umtykx/AAAY2Uoq93C4T7kC5JqhezCga?dl=0

Link to comment
Share on other sites

3 hours ago, sacredbacon said:

Thank you for the help, that's really interesting. I'm certain that I am on 1.10.1 now if I wasn't already and I'm still getting the same error. Crash on "Module Manager: Running Post Patch Callbacks. Here's some new logs:

https://www.dropbox.com/sh/jsh7cyny5umtykx/AAAY2Uoq93C4T7kC5JqhezCga?dl=0

Dude, there're a lot of weird exceptions scattered on the log:

[AddonLoader]: Instantiating addon '_BuildManager' from assembly '_BuildManager'

(Filename: C:\buildslave\unity\build\Runtime/Export/Debug/Debug.bindings.h Line: 35)

Uploading Crash Report
NotSupportedException: The invoked member is not supported in a dynamic module.
  at System.Reflection.Emit.AssemblyBuilder.get_Location () [0x00006] in <ad04dee02e7e4a85a1299c7ee81c79f6>:0
  at _BuildManager._BuildManager+<>c__DisplayClass2_0.<logVersion>b__0 (System.Reflection.Assembly x) [0x00000] in <caa8a9a07bbf48af914d3a76740b33a6>:0
  at System.Linq.Enumerable+WhereSelectArrayIterator`2[TSource,TResult].ToList () [0x00019] in <fbb5ed17eb6e46c680000f8910ebb50c>:0
  at System.Linq.Enumerable.ToList[TSource] (System.Collections.Generic.IEnumerable`1[T] source) [0x0001f] in <fbb5ed17eb6e46c680000f8910ebb50c>:0
  at _BuildManager._BuildManager.logVersion () [0x0005c] in <caa8a9a07bbf48af914d3a76740b33a6>:0
  at _BuildManager._BuildManager.Awake () [0x00000] in <caa8a9a07bbf48af914d3a76740b33a6>:0
Uploading Crash Report
CustomAttributeFormatException: Could not find a field with name guiName
  at (wrapper managed-to-native) System.MonoCustomAttrs.GetCustomAttributesInternal(System.Reflection.ICustomAttributeProvider,System.Type,bool)
  at System.MonoCustomAttrs.GetCustomAttributesBase (System.Reflection.ICustomAttributeProvider obj, System.Type attributeType, System.Boolean inheritedOnly) [0x00013] in <a
  at System.MonoCustomAttrs.GetCustomAttributes (System.Reflection.ICustomAttributeProvider obj, System.Type attributeType, System.Boolean inherit) [0x00037] in <ad04dee02e7
  at System.Reflection.MonoMethod.GetCustomAttributes (System.Type attributeType, System.Boolean inherit) [0x00000] in <ad04dee02e7e4a85a1299c7ee81c79f6>:0
  at BaseEventList+ReflectedData..ctor (System.Type type) [0x00052] in <c1858a3f77504bd1aaa946fdccf84670>:0
  at BaseEventList.GetReflectedAttributes (System.Type type) [0x00026] in <c1858a3f77504bd1aaa946fdccf84670>:0
  at BaseEventList.CreateDelegates (System.Object part) [0x0000b] in <c1858a3f77504bd1aaa946fdccf84670>:0
  at BaseEventList..ctor (Part part, PartModule module) [0x0003c] in <c1858a3f77504bd1aaa946fdccf84670>:0
  at PartModule.ModularSetup () [0x00007] in <c1858a3f77504bd1aaa946fdccf84670>:0
  at PartModule.Awake () [0x00023] in <c1858a3f77504bd1aaa946fdccf84670>:0
PartLoader: Encountered exception during compilation. System.NullReferenceException: Object reference not set to an instance of an object
  at PartModule.Load (ConfigNode node) [0x0010d] in <c1858a3f77504bd1aaa946fdccf84670>:0
  at Part.AddModule (ConfigNode node, System.Boolean forceAwake) [0x0006f] in <c1858a3f77504bd1aaa946fdccf84670>:0
  at PartLoader.ParsePart (UrlDir+UrlConfig urlConfig, ConfigNode node) [0x00f10] in <c1858a3f77504bd1aaa946fdccf84670>:0
  at PartLoader+<CompileParts>d__56.MoveNext () [0x005cd] in <c1858a3f77504bd1aaa946fdccf84670>:0

And a lot more repetitions of that pattern. The trigger (but not the culprit, I think) for the the final crash is:

Uploading Crash Report
StackOverflowException: The requested operation caused a stack overflow.
  at InterstellarFuelSwitch.InterstellarFuelSwitch.nextTankSetupEvent () [0x00062] in <d01e29ea4c244ea6a8ffa3a0882ff107>:0
  at InterstellarFuelSwitch.InterstellarFuelSwitch.nextTankSetupEvent () [0x00062] in <d01e29ea4c244ea6a8ffa3a0882ff107>:0
  <repeat the last line ad nauseaum>

This sounds as file corruption. Some of that Add'Ons are known to me, and they didn't ever triggered such Exceptions here - so it must be something environmental. Perhaps something truncated or zeroed some of the files? (someone call tell me if crosslinked clusters are possible on NTFS?)

Some file system corruption ended up It sounds like the most plausible explanation (but I'm guessing).

You will need to brute force your way out of the mess. Remove everything from the game to another directory (remove, not delete). Then reinstall things from scratch - remember to do not fire up your savegames - create new ones for the test, don't allow KSP to touch anything you value on these tests.

Use new, fresh downloads of the add'ons - just to be on the safe side of the force. If you manage to rebuilt your installment and get free of errors, copy back the savegames and try them. If not, publish the new Player.log (but add also the KSP.log too - some things are easier to read from it) and let's see what changed.

On the worst scenario, perhaps you have a hardware problem, being bad memory the most common of them (otherwise your rig would not even boot up). Doing a memory test would not be a bad idea.

Link to comment
Share on other sites

I got it, I'm really not sure what hung up the loading process on "Module Manager: Running Post Patch Callbacks" , but it's likely just as you said. What I can say specifically is that Baha SP prevented me from passing me through "Expansion Loading Complete" and the 2x1 greenhouse from LLL and light globe from KAS/KIS also prevented loading.

I installed things in batches correcting as I installed and now it works, thank you for all the help! Its hard to get these all these mods to play nice together!

Edited by sacredbacon
Link to comment
Share on other sites

  • 9 months later...
On 9/6/2020 at 7:46 AM, Lisias said:

Some file system corruption ended up It sounds like the most plausible explanation

for anyone else who encounters this, I'm going to emphasize the above possibility since I have a 1.10.1 install that loads just fine 1/2 of the time & but has this hang on "Running Post Patch Callbacks" during the other half of loads with 'no changes'...so far rebooting the offending machine & deleting the MM cache in GameData folder seems to help in my case...(my gut feel observation on this machine is that it is related to memory instability/corruption induced by an occasional driver or AV conflict since, despite my maintenance efforts,  I still occasionally see an IRQL or related BSOD on occasion...)

Edited by AloE
Link to comment
Share on other sites

5 hours ago, AloE said:

for anyone else who encounters this, I'm going to emphasize the above possibility since I have a 1.10.1 install that loads just fine 1/2 of the time & but has this hang on "Running Post Patch Callbacks" during the other half of loads with 'no changes'...so far rebooting the offending machine & deleting the MM cache in GameData folder seems to help in my case...(my gut feel observation on this machine is that it is related to memory instability/corruption induced by an occasional driver or AV conflict since, despite my maintenance efforts,  I still occasionally see an IRQL or related BSOD on occasion...)

I have another plausible explanation for this. One that I just detected, by the way,

I made a mishap on an add'on in which I ended up abusing the Garbage Collector. On a sane system, I would be causing some stuttering but on Unity I ended up locking the whole program - it happens that when the Garbage Collector is collecting, everybody else needs to halt waiting for it (you can't easily allocate or access memory in the mean time, as the GC is meddling with the heap). Apparently, Unity is using spinlocks on the waiting threads, and this is plain stupid on a heavy threaded system!

Every waiting thread using a spinlock would  occupy a CPU (or a hardware thread on a CPU - a hyperthread as Intell calls them), and since we have a very finite number of CPUs available, if you have threads enough waiting for the GC, the high number of spinlocks will halt the whole process, as they will compete with the GC thread - the spinlocks will prevent the GC from running while the spinlocks wait for the GC to terminate its business - a catch 22 situation.

Module Manager, by its own nature, is another piece of code that heavily stress the Garbage Collector.

I also had a borderline situation on MM where a reboot had solved the issue, what's plain nuts because the OS (MacOS on my case) zero up the memory before giving it to a process. So memory corruption is not an option (mainly because nothing else on the system crashes). But the use of spinlocks where a MUTEX is needed explains this problem - MacOS is nasty with memory hungry processes, as it compresses memory on the fly (RAM Doubler or SoftRAM style, for people that tried this stunt on Windows 3 and 95), and these things also taxes the CPU. If you have a lot of spinlocks bullying the CPU, everything on the system will slow down, including a simple malloc.

Edited by Lisias
tyops
Link to comment
Share on other sites

On 6/23/2021 at 5:06 PM, Lisias said:

the high number of spinlocks will halt the whole process, as they will compete with the GC thread - the spinlocks will prevent the GC from running while the spinlocks wait for the GC to terminate its business - a catch 22 situation.

Module Manager, by its own nature, is another piece of code that heavily stress the Garbage Collector.

That indeed sounds like it matches well the "looks like KSP in purgatory"...lol...symptom I am seeing...& from what you wrote it sounds like from the user side there is not much I could do on heavily modded installs to mitigate the chance of that 'catch 22' occurring?

Link to comment
Share on other sites

2 minutes ago, AloE said:

That indeed sounds like it matches well the "looks like KSP in purgatory"...lol...symptom I am seeing...& from what you wrote it sounds like from the user side there is not much I could do on heavily modded installs to mitigate the chance of that 'catch 22' occurring?

Nope.

If I'm right (and things appears to confirm my hypothesis until this moment), there's really nothing one can do - no even Squad - as this is a Unity problem deeply buried on its guts.

Theoretically, this can be fixed by some pretty nasty patching (Unity has its source available, it's possible - besides unplausible -to replace all the code that does spinlock into code that does proper mutexes.

Obviously, this will void your warranty... By a parsec. :P  (not to mention the amount of potential problems you can inject on the stack by meddling so deeply on the Engine...)

Link to comment
Share on other sites

This thread is quite old. Please consider starting a new thread rather than reviving this one.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...