Log in or register to post comments

Exception in callback

August 30, 2019 - 2:05pm #1

I am getting an exception inside VuforiaBehaviour.Update() that occurs when tracking begins, when an object is found. This error occurs in the editor. The callstack is below. Although this doesn't seem to be interfering with my app, it does make me think that I am doing something wrong.

Could someone review this callstack and suggest perhaps what is causing this?

I am using Unity 2019.2.2f1, with Vuforia 8.3.8.

Exception in callback: System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> System.InvalidOperationException: Collection was modified; enumeration operation may not execute.

at System.Collections.Generic.Dictionary`2+ValueCollection+Enumerator[TKey,TValue].MoveNext () [0x00013] in <ad04dee02e7e4a85a1299c7ee81c79f6>:0

at System.Linq.Enumerable+WhereEnumerableIterator`1[TSource].MoveNext () [0x0004e] in <fbb5ed17eb6e46c680000f8910ebb50c>:0

at Vuforia.StateManager.UpdateTrackableStates (Vuforia.TrackerData+TrackableResultData[] trackableResults) [0x0010c] in <21bfe61d2ac241f6a9131b858645aad9>:0

at Vuforia.StateManager.UpdateTrackablePoses (UnityEngine.Vector3 positionalOffset, UnityEngine.Quaternion rotationalOffset, Vuforia.TrackerData+TrackableResultData[] trackableResultDataArray, Vuforia.TrackerData+VuMarkTargetResultData[] vuMarkResultDataArray, Vuforia.VuforiaManager+TrackableIdPair originTrackableID, System.Int32 frameIndex, System.Boolean updateTrackableStates) [0x000e3] in <21bfe61d2ac241f6a9131b858645aad9>:0

at Vuforia.StateManager.UpdateTrackablePoses (UnityEngine.Vector3 positionalOffset, UnityEngine.Quaternion rotationalOffset, Vuforia.TrackerData+TrackableResultData[] trackableResultDataArray, Vuforia.TrackerData+VuMarkTargetResultData[] vuMarkResultDataArray, Vuforia.VuforiaManager+TrackableIdPair originTrackableID, System.Int32 frameIndex) [0x00000] in <21bfe61d2ac241f6a9131b858645aad9>:0

at Vuforia.VuforiaManager.UpdateTrackers (Vuforia.TrackerData+FrameState frameState) [0x002a6] in <21bfe61d2ac241f6a9131b858645aad9>:0

at Vuforia.VuforiaManager.Update (UnityEngine.ScreenOrientation counterRotation, System.Boolean& reapplyOldState) [0x0018c] in <21bfe61d2ac241f6a9131b858645aad9>:0

at Vuforia.VuforiaARController.UpdateStatePrivate (System.Boolean forceUpdate, System.Boolean reapplyOldState) [0x00061] in <21bfe61d2ac241f6a9131b858645aad9>:0

at Vuforia.VuforiaARController.UpdateState (System.Boolean forceUpdate, System.Boolean reapplyOldState) [0x0000c] in <21bfe61d2ac241f6a9131b858645aad9>:0

at Vuforia.DigitalEyewearARController.Update () [0x00000] in <21bfe61d2ac241f6a9131b858645aad9>:0

at (wrapper managed-to-native) System.Reflection.MonoMethod.InternalInvoke(System.Reflection.MonoMethod,object,object[],System.Exception&)

at System.Reflection.MonoMethod.Invoke (System.Object obj, System.Reflection.BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) [0x00032] in <ad04dee02e7e4a85a1299c7ee81c79f6>:0

  --- End of inner exception stack trace ---

at System.Reflection.MonoMethod.Invoke (System.Object obj, System.Reflection.BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) [0x00048] in <ad04dee02e7e4a85a1299c7ee81c79f6>:0

at System.Reflection.MethodBase.Invoke (System.Object obj, System.Object[] parameters) [0x00000] in <ad04dee02e7e4a85a1299c7ee81c79f6>:0

at System.Delegate.DynamicInvokeImpl (System.Object[] args) [0x000e7] in <ad04dee02e7e4a85a1299c7ee81c79f6>:0

at System.MulticastDelegate.DynamicInvokeImpl (System.Object[] args) [0x00008] in <ad04dee02e7e4a85a1299c7ee81c79f6>:0

at System.Delegate.DynamicInvoke (System.Object[] args) [0x00000] in <ad04dee02e7e4a85a1299c7ee81c79f6>:0

at Vuforia.DelegateHelper.InvokeDelegate (System.Delegate action, System.Object[] args) [0x0000f] in <21bfe61d2ac241f6a9131b858645aad9>:0

UnityEngine.Debug:LogError(Object)

Vuforia.DelegateHelper:InvokeDelegate(Delegate, Object[])

Vuforia.DelegateHelper:InvokeWithExceptionHandling(Action)

Vuforia.VuforiaBehaviour:Update()

Exception in callback

September 4, 2019 - 11:41am #2

I see in this post - https://developer.vuforia.com/forum/unity/exception-when-initialising-targets-switching-scenes - that a user has had a similar internal error. And the post says that the error has been fixed in Vuforia 8.5.

When will that version 8.5 be available as a Unity package?

Log in or register to post comments