Search Issue Tracker
Fixed in 5.0.X
Votes
5
Found in
4.3.1f1
Issue ID
580667
Regression
No
Loading of serialized specific ScriptableObject fails with System.ArgumentOutOfRangeException
The reproduction project has complex ScriptableObject hierarchy. Application fails with such error, which could vary with project/version:
Exception: Non-negative number required.Parameter name: capacity
Type: System.ArgumentOutOfRangeException
Module: mscorlib
InnerException: <No Data>
AdditionalInfo:Invoking UnityEngine.IUnitySerializable::Unity_Deserialize method with argument count: 0
at System.ThrowHelper.ThrowArgumentOutOfRangeException(ExceptionArgument argument, ExceptionResource resource)
at System.Collections.Generic.List`1..ctor(Int32 capacity)
at <Custom Class>.Unity_Deserialize()
at lambda_method(Closure , Object , Object[] , Int32 )
at WinRTBridge.MethodTools.InvokeMethod(Object instance, Int32 methodIndex, Object[] args)
(Filename: Line: 65)
A script behaviour has a different serialization layout when loading. (Read 888 bytes but expected 2527120 bytes)
Did you #ifdef UNITY_EDITOR a section of your serialized properties in any of your scripts?
Comments (3)
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
- Mono Windows Builds don't produce full log callstacks when generating logs
- AssetBundles fail to load when running in Built Players for Mobile Devices
- UI elements with text gets bigger and grey when Player window is moved to another screen with different resolution
- System name accepts multiline text but crops it on confirmation, duplicates input, and shrinks the field when empty
- UI element scale and position are wrong in project build when DRS is changed with HDR and Software Dynamic Resolution enabled
deepesh
May 07, 2014 09:51
Hi All,
I am also getting something similar kind of error when running a windows store app build but its System.ArgumentOutOfMemory Exception instead of System.ArgumentOutOfRangeException
:Exception: Exception of type 'System.OutOfMemoryException' was thrown.
Type: System.OutOfMemoryException
Module: WinRTBridge
InnerException: <No Data>
AdditionalInfo:Invoking UnityEngine.IUnitySerializable::Unity_Deserialize method with argument count: 0
at WinRTBridge.SerializationWeaverReader.ReadString()
at AvatarPartTab.Unity_Deserialize()
at UiAvatarCustomization.Unity_Deserialize()
at lambda_method(Closure , Object , Object[] , Int32 )
at WinRTBridge.MethodTools.InvokeMethod(Object instance, Int32 methodIndex, Object[] args)
(Filename: C:/BuildAgent/work/d3d49558e4d408f4/Runtime/Scripting/WinRTUtility.cpp Line: 65)
A script behaviour has a different serialization layout when loading. (Read 320 bytes but expected 5952 bytes)
Did you #ifdef UNITY_EDITOR a section of your serialized properties in any of your scripts?
Is it related to this exception?, or someone can give me solution for this?
Thanks In Advance!
Arkanoid
Mar 03, 2014 14:26
still present in 4.3.4
soulburner
Dec 20, 2013 12:31
Waiting for a fix! Thank you.