Search Issue Tracker
Fixed in 0.5.0-preview.5
Votes
0
Found in [Package]
0.3.0-preview.3
Issue ID
1279664
Regression
Yes
[NetCode] InvalidOperationException is thrown in build when scripting backend is set to IL2CPP
Reproduction steps:
1. Open attached project "Case_1279664"
2. Click File -> Build Settings... and check "Development Build"
3. Build and Run the project
4. Observe the Build's Console
Expected result: no errors are thrown
Actual result: "InvalidOperationException: Unexpected 0 hash for type" is thrown twice
Reproducible with: 0.3.0-preview.3, 0.4.0-preview.1 (2020.1.10f1, 2020.2.0b8, 2021.1.0a2)
Not reproducible with: 2018.4.28f1 (NetCode not available) 2019.4.13f1 (Reproducible package version not available)
Full Exception:
InvalidOperationException: Unexpected 0 hash for type
at Unity.NetCode.GhostCollectionSystem.HashGhostComponentSerializer (Unity.NetCode.LowLevel.Unsafe.GhostComponentSerializer+State& comp) [0x00000] in <00000000000000000000000000000000>:0
at Unity.NetCode.GhostCollectionSystem.AddSerializer (Unity.NetCode.LowLevel.Unsafe.GhostComponentSerializer+State state) [0x00000] in <00000000000000000000000000000000>:0
at Unity.NetCode.Generated.GhostComponentSerializerRegistrationSystem.OnCreate () [0x00000] in <00000000000000000000000000000000>:0
at Unity.Entities.ComponentSystemBase.CreateInstance (Unity.Entities.World world) [0x00000] in <00000000000000000000000000000000>:0
at Unity.Entities.World.AddSystem_OnCreate_Internal (Unity.Entities.ComponentSystemBase system) [0x00000] in <00000000000000000000000000000000>:0
at Unity.Entities.World.GetOrCreateSystemsAndLogException (System.Collections.Generic.IEnumerable`1[T] types, System.Int32 typesCount) [0x00000] in <00000000000000000000000000000000>:0
at Unity.Entities.DefaultWorldInitialization.AddSystemToRootLevelSystemGroupsInternal (Unity.Entities.World world, System.Collections.Generic.IEnumerable`1[T] systemTypesOrig, System.Int32 managedTypesCountOrig) [0x00000] in <00000000000000000000000000000000>:0
at Unity.Entities.DefaultWorldInitialization.Initialize (System.String defaultWorldName, System.Boolean editorWorld) [0x00000] in <00000000000000000000000000000000>:0
Unity.Entities.World:GetOrCreateSystemsAndLogException(IEnumerable`1, Int32)
Unity.Entities.DefaultWorldInitialization:AddSystemToRootLevelSystemGroupsInternal(World, IEnumerable`1, Int32)
Unity.Entities.DefaultWorldInitialization:Initialize(String, Boolean)
Add comment
All about bugs
View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.
Latest issues
- Crash on when D3D12RenderPass::SetupDeviceResources when opening FBX animation preview
- Serialization errors are thrown when "com.unity.render-pipelines.core" is added as a custom package and Graphics window is opened
- Character Joints unexpectedly rotate when a ragdoll is created using the Ragdoll Wizard
- Crash on GfxDeviceD3D11Base::DrawBuffersBatchMode when rendering the Scene view
- The shared EditorBuildSettings.asset file of symlinked projects is not updated when changing the order of the Scenes in Build Settings in one of the projects
Resolution Note (fix version 0.5.0-preview.5):
Fixed in: Unity NetCode 0.5.0 - preview.5