Search Unity

Unity4.3 Error on device, Type: System.Runtime.InteropServices.SEHException

Discussion in 'Windows' started by Jmonroe, Nov 21, 2013.

  1. Jmonroe

    Jmonroe

    Joined:
    Jul 7, 2012
    Posts:
    87
    I'm using Unity4.3.0 and getting the following exception in the UnityPlayer log every time I run the game on the WP8 device. Game doesn't crash, but using the profiler it seems the memory starts to climb rapidly following the error.

    Exception: External component has thrown an exception.
    Type: System.Runtime.InteropServices.SEHException
    Module: UnityEngineProxy
    InnerException: <No Data>
    AdditionalInfo:Invoking UnityEngine.SendMouseEvents::DoSendMouseEvents method with argument count: 2
    at UnityEngineProxy.InternalCalls.Component_CUSTOM_GetComponent(Object self, Object type)

    at UnityEngine.SendMouseEvents.DoSendMouseEvents(Int32 mouseUsed, Int32 skipRTCameras)

    at lambda_method(Closure , Object , Object[] , Int32 )

    at WinRTBridge.MethodTools.InvokeMethod(Object instance, Int32 methodIndex, Object[] args)
     
    Last edited: Nov 21, 2013
  2. Tautvydas-Zilys

    Tautvydas-Zilys

    Unity Technologies

    Joined:
    Jul 25, 2013
    Posts:
    6,540
    Hello. This is a known issue and are working at getting a fix out ASAP. Until then, the best you can do it wait...
     
  3. mkg2w

    mkg2w

    Joined:
    Aug 19, 2013
    Posts:
    38
    Is there any update on this error ? We're seeing a similar error very regularly in our WP build.

    What's the origin of this error ; is this specific to Windows Store applications? i.e. what about Windows Desktop Apps?
     
  4. Tomas1856

    Tomas1856

    Unity Technologies

    Joined:
    Sep 21, 2012
    Posts:
    1,989
    Try switching to 4.3.1, it should have been fixed there.
     
  5. jalemanyf

    jalemanyf

    Joined:
    Jun 16, 2013
    Posts:
    16
    I'm working on Unity 4.3.2f1 and got the same problema when I try to use the WebCam:

    WebCamDevice[] devices = WebCamTexture.devices;
     
  6. Tautvydas-Zilys

    Tautvydas-Zilys

    Unity Technologies

    Joined:
    Jul 25, 2013
    Posts:
    6,540
    What happens exactly?
     
  7. raynaldo

    raynaldo

    Joined:
    Oct 7, 2013
    Posts:
    15
    any update on this?
    i still get the same error on Unity 4.3.2f1


    Code (csharp):
    1. Exception: External component has thrown an exception.
    2. Type: System.Runtime.InteropServices.SEHException
    3. Module: UnityEngineProxy
    4. InnerException: <No Data>
    5. AdditionalInfo:<No Data>
    6.    at UnityEngineProxy.InternalCalls.Transform_CUSTOM_INTERNAL_get_position(Object self, Int32 paramValue)
    7.  
    8.    at UnityEngine.Transform.INTERNAL_get_position(Vector3 value)
    9. ..........................
    *this error happens only in Master configuration when parenting transform via script
     
    Last edited: Jan 7, 2014
  8. Tautvydas-Zilys

    Tautvydas-Zilys

    Unity Technologies

    Joined:
    Jul 25, 2013
    Posts:
    6,540
    Hmm that's strange, the issue that was really common and showed up everytime was fixed in 4.3.1. Can you report a bug?
     
  9. Lexustio

    Lexustio

    Joined:
    Jun 26, 2013
    Posts:
    18
    Same problem, except with windows store apps. Haven't had this before (I've deployed plenty of apps to the same device in question).

    Unity version is 4.3.2f1
     
  10. Tautvydas-Zilys

    Tautvydas-Zilys

    Unity Technologies

    Joined:
    Jul 25, 2013
    Posts:
    6,540
    Can you report a bug with a repro project attached?
     
  11. raynaldo

    raynaldo

    Joined:
    Oct 7, 2013
    Posts:
    15
    4.3.3 here.
    Exception when trying to "GetComponent<Transform>()" from a MonoBehaviour.

    Code (csharp):
    1. Exception: External component has thrown an exception.
    2. Type: System.Runtime.InteropServices.SEHException
    3. Module: UnityEngineProxy
    4. InnerException: <No Data>
    5. AdditionalInfo:<No Data>
    6.    at UnityEngineProxy.InternalCalls.Component_CUSTOM_GetComponent(Object self, Object type)
    7.    at UnityEngine.Component.GetComponent[T]()
    8. .................................
    The bug is occured occasionally when I build the game.
    *Sometimes there's no exception if i rebuild the game.
     
  12. Tautvydas-Zilys

    Tautvydas-Zilys

    Unity Technologies

    Joined:
    Jul 25, 2013
    Posts:
    6,540
    Well, the only thing I can advice is to fill a bug report. We still don't have a repro and I have no idea what could cause this.
     
  13. Travis-Bulford

    Travis-Bulford

    Joined:
    Feb 14, 2013
    Posts:
    257
    Has a bug for this been logged? I can not find one in the bug system we getting a similar error.

    Exception: External component has thrown an exception.
    Type: System.Runtime.InteropServices.SEHException
    Module: UnityEngineProxy
    InnerException: <No Data>
    AdditionalInfo:<No Data>
    at UnityEngineProxy.InternalCalls.PInvokeCalls.GameObject_CUSTOM_GetComponentByName(Int32 param_0, Int32 param_1)
    at UnityEngineProxy.InternalCalls.GameObject_CUSTOM_GetComponentByName(Object self, String type)
    at SpriteFactory.GetFromCache(String sprite)
    at SpriteFactory.CachedGameObject(Int32 x, Int32 y, String scriptname)
    at SpriteFactory.NewSplat(Int32 x, Int32 y)
    at Goop.FixedUpdate()
    at Goop.UnityFastInvoke_FixedUpdate()

    This is invoked in the code below. We are fetching a game object from a cache list. I am evaluating if we have accidentally kept the cached list between levels and the gameObjects we are searching for are actually destroyed. I don't suspect so though since we don't see this all the time.

    Code (csharp):
    1.  
    2.     public static GameObject GetFromCache(string sprite){
    3.         if (cachedSprites.ContainsKey(sprite)){
    4.             List<GameObject> list=cachedSprites[sprite];
    5.             if (list.Count>0){
    6.                 GameObject gameObject=list[list.Count-1];
    7.                 list.RemoveAt(list.Count-1);
    8.                 if (sprite.EndsWith("Center")){
    9.                     sprite=sprite.Substring(0,sprite.Length-6);
    10.                 }
    11.                 Sprite s=(Sprite)gameObject.GetComponent(sprite);
    12.                 s.enabled=true;
    13.                 s.renderer.enabled=true;
    14.                 s.instantMove=true;
    15.                 s.currentSprite=-1;
    16.                
    17.                 return gameObject;
    18.             }
    19.         }
    20. #if UNITY_EDITOR
    21.         Debug.Log ("Cache Miss "+sprite);
    22. #endif
    23.         return null;
    24.     }
    25.  
     
  14. Tautvydas-Zilys

    Tautvydas-Zilys

    Unity Technologies

    Joined:
    Jul 25, 2013
    Posts:
    6,540
    Hi,

    we did not receive a bug report nor we were able to reproduce it ourselves. Please submit it if you can.

    In the meanwhile, could you try using gameObject.GetComponent<Sprite>() instead of non generic version? It should perform better and since the exception is thrown on that line, it may be able to fix it.
     
  15. kanyka

    kanyka

    Joined:
    Jul 20, 2014
    Posts:
    5
    Hi,
    I using 4.5.3f get pretty same error message, for controller I use standard script from standard asset(mobile).
     

    Attached Files:

  16. ddoreto

    ddoreto

    Joined:
    Feb 23, 2014
    Posts:
    1
  17. Tautvydas-Zilys

    Tautvydas-Zilys

    Unity Technologies

    Joined:
    Jul 25, 2013
    Posts:
    6,540
    Hi,

    thanks for reporting the issue! The fix should be included into next weeks patch release (it was too late to include it to tomorrows release).