Search Issue Tracker

Won't Fix

Votes

0

Found in

6000.0.56f1

6000.2.2f1

6000.3.0a6

6000.4.0a1

Issue ID

UUM-116525

Regression

Yes

Crash on object:runtime_invoke_void__this__ when opening a specific project

-

How to reproduce:
1. Open the attached “IN-112699“ project
2. Loads the Startup scene
3. Enter Play mode
4. Observe the crash

Reproducible with: 2023.3.0a12, 6000.0.56f1, 6000.2.2f1, 6000.3.0a6
Not reproducible with: 2023.3.0a11

Reproducible on: MacOS 15.6.1 (M4), Windows 11 (by user)
Not reproducible on: No other environments tested

Notes:
- Deleting the project library folder fixes the crash.
- Project crashes when opening certain scenes in Unity versions 2022.3, 6000.0, 6000.2, and 6000.3
- The Lobby.unity scene can be entered without crashing

First few lines of the stack trace (Windows 11):
{noformat}
0x000001C72E11DE38 (Mono JIT Code) (wrapper runtime-invoke) object:runtime_invoke_void__this__ (object,intptr,intptr,intptr)
0x00007FFF7B376C4E (mono-2.0-bdwgc) [C:\build\output\Unity-Technologies\mono\mono\mini\mini-runtime.c:3445] mono_jit_runtime_invoke
0x00007FFF7B2B8604 (mono-2.0-bdwgc) [C:\build\output\Unity-Technologies\mono\mono\metadata\object.c:3068] do_runtime_invoke
0x00007FFF7B2B86F0 (mono-2.0-bdwgc) [C:\build\output\Unity-Technologies\mono\mono\metadata\object.c:3115] mono_runtime_invoke
0x00007FFF80AEAFA5 (Unity) mono_runtime_object_init_exception
0x00007FFF80B49770 (Unity) scripting_unity_engine_object_new_and_invoke_default_constructor
0x00007FFF80BCBEAD (Unity) SerializableManagedRef::RebuildMonoInstance{noformat}
First few lines of the stack trace (MacOS):
{noformat}
#0 0x0000043f7ec7dc in EasyJection.Hooking.HookManager:Hook () [{0x11ebbf9f8} + 0xf4] [/Users/andreja.borisovaite/Desktop/IN-112699_Card-Match-Prototype/Assets/ThirdParties/EasyJection/Runtime/Framework/Hooking/Implementions/HookManager.cs :: 183u] (0x43f7ec6e8 0x43f7ec81c) [0x342ecea80 - Unity Child Domain]
#1 0x0000043f7ec5c0 in EasyJection.Hooking.HookManager:.ctor (EasyJection.Hooking.IMethodInvokeData,System.Reflection.MethodBase,System.Reflection.MethodBase,bool) [{0x11ebbf828} + 0x100] [/Users/andreja.borisovaite/Desktop/IN-112699_Card-Match-Prototype/Assets/ThirdParties/EasyJection/Runtime/Framework/Hooking/Implementions/HookManager.cs :: 94u] (0x43f7ec4c0 0x43f7ec5d4) [0x342ecea80 - Unity Child Domain]
#2 0x0000043f7ebd28 in EasyJection.Hooking.HookedMethodVoid:.ctor (EasyJection.Hooking.IHookContainer,System.Reflection.MethodBase) [{0x11ec2ae40} + 0x740] [/Users/andreja.borisovaite/Desktop/IN-112699_Card-Match-Prototype/Assets/ThirdParties/EasyJection/Runtime/Framework/Hooking/Implementions/HookedMethodVoid.cs :: 136u] (0x43f7eb5e8 0x43f7ebd7c) [0x342ecea80 - Unity Child Domain]
#3 0x0000043f7eaf04 in EasyJection.Binding.BindingInjectionConditionFactory:Constructor (bool) [{0x11ec27ac0} + 0x114] [/Users/andreja.borisovaite/Desktop/IN-112699_Card-Match-Prototype/Assets/ThirdParties/EasyJection/Runtime/Framework/Binding/Implemantions/BindingInjectionConditionFactory.cs :: 55u] (0x43f7eadf0 0x43f7eaf38) [0x342ecea80 - Unity Child Domain]
#4 0x0000043f7ea814 in EasyJection.Binding.BindingInjectionFactory:Constructor (bool) [{0x11ec13660} + 0x44] [/Users/andreja.borisovaite/Desktop/IN-112699_Card-Match-Prototype/Assets/ThirdParties/EasyJection/Runtime/Framework/Binding/Implemantions/BindingInjectionFactory.cs :: 52u] (0x43f7ea7d0 0x43f7ea820) [0x342ecea80 - Unity Child Domain]
#5 0x0000043f7ea58c in EasyJection.Binding.BindingFactory:AddBinding (object,EasyJection.Binding.BindingInstanceType,bool) [{0x378b843e0} + 0x164] [/Users/andreja.borisovaite/Desktop/IN-112699_Card-Match-Prototype/Assets/ThirdParties/EasyJection/Runtime/Framework/Binding/Implemantions/BindingFactory.cs :: 98u] (0x43f7ea428 0x43f7ea5ac) [0x342ecea80 - Unity Child Domain]
#6 0x0000043f7ea350 in EasyJection.Binding.BindingFactory:ToSelf (bool) [{0x378b84788} + 0x50] [/Users/andreja.borisovaite/Desktop/IN-112699_Card-Match-Prototype/Assets/ThirdParties/EasyJection/Runtime/Framework/Binding/Implemantions/BindingFactory.cs :: 194u] (0x43f7ea300 0x43f7ea388) [0x342ecea80 - Unity Child Domain]{noformat}

  1. Resolution Note:

    We have decided to close this issue as "Won't Fix" at this time. If you believe this decision should be reconsidered, please provide the minimal reproducer.

    Root Cause of the crash is due to a conflict between the third-party EasyJection library and Unity's serialization system. EasyJection modifies internal method address pointers to inject custom constructors for dependency injection, which interferes with Unity's direct object instantiation during deserialization.

    Recommended workaround is to use the [SerializeReference] attribute on polymorphic members to resolve the crash. This prevents Unity's by-value serialization from conflicting with EasyJection's method hooking system.

Add comment

Log in to post comment

All about bugs

View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.