Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 13 Next capture
2021 2022 2023
1 capture
13 Jun 22 - 13 Jun 22
sparklines
Close Help
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
avatar image
0
Question by DaMex · May 29, 2015 at 09:22 AM · il2cpppush notificationaot

ExecutionEngineException - Error at iOS Runtime with parse.com SDK

We're creating a game for iOS and android using Unity3d (version 5.0.1p1), and since we are using Parse.com data services we naturally went with it to implement the remote push notifications.

The problem is that after building the game and running it on a test device (iPhone 4s iOS8.1.2) we get at game start an execution engine exception that we cant figure out. Here is the exception :

 ExecutionEngineException: Attempting to call method
 
 'System.Reflection.MonoProperty::StaticGetterAdapterFrame' for which no ahead of time (AOT) code was
 
 generated.
 
 at System.Reflection.EventInfo+AddEventAdapter.Invoke (System.Object _this, System.Delegate dele)
 
 [0x00000] in <filename unknown>:0
 
 at System.Reflection.MonoProperty+GetterAdapter.Invoke (System.Object _this) [0x00000] in <filename
 
 unknown>:0
 
 at AOGenerator.BlurBuffer () [0x00000] in <filename unknown>:0
 
 at System.Reflection.MonoProperty.GetValue (System.Object obj, System.Object[] index) [0x00000] in
 
 <filename unknown>:0
 
 at Newtonsoft.Json.Bson.BsonRegex.get_Type () [0x00000] in <filename unknown>:0
 
 at Parse.ParseInstallation.get_Badge () [0x00000] in <filename unknown>:0
 
 at Parse.ParseInstallation.SetPlatformAutomaticValue () [0x00000] in <filename unknown>:0
 
 at Parse.ParseInstallation.SetAutomaticValues () [0x00000] in <filename unknown>:0
 
 at Parse.ParseInstallation.SaveAsync (System.Threading.Tasks.Task toAwait, CancellationToken
 
 cancellationToken) [0x00000] in <filename unknown>:0
 
 at Parse.PlatformHooks+<>c__DisplayClass38.<RequestAsync>b__33 (System.Threading.Tasks.Task`1 _)
 
 [0x00000] in <filename unknown>:0
 
 at Parse.ParseObject+<>c__DisplayClass18.<SaveAsync>b__17 (System.Threading.Tasks.Task toAwait)
 
 [0x00000] in <filename unknown>:0
 
 at FlurryAnalyticsIOS.SetSessionTimeout (Int32 seconds) [0x00000] in <filename unknown>:0
 
 at
 
 System.Collections.Generic.Dictionary`2[System.Int64,System.Boolean].Do_ICollectionCopyTo[KeyValuePair`2]
 
 (System.Array array, Int32 index, System.Collections.Generic.Transform`1 transform) [0x00000] in <filename
 
 unknown>:0
 
 at Parse.Internal.TaskQueue.Enqueue[Task] (System.Func`2 taskStart, CancellationToken cancellationToken)
 
 [0x00000] in <filename unknown>:0
 
 at Parse.ParseObject.SaveAsync (CancellationToken cancellationToken) [0x00000] in <filename unknown>:0
 
 at Parse.ParseObject.SaveAsync () [0x00000] in <filename unknown>:0
 
 at Parse.ParseInitializeBehaviour.<Awake>b__0 (System.Byte[] deviceToken) [0x00000] in <filename
 
 unknown>:0
 
 at FlurryAnalyticsIOS.SetSessionTimeout (Int32 seconds) [0x00000] in <filename unknown>:0
 
 at Newtonsoft.Json.Bson.BsonRegex.get_Type () [0x00000] in <filename unknown>:0
 
 at Parse.PlatformHooks+<>c__DisplayClass24.<RegisterDeviceTokenRequest>b__22 () [0x00000] in
 
 <filename unknown>:0
 
 at System.Action.Invoke () [0x00000] in <filename unknown>:0
 
 at Newtonsoft.Json.Bson.BsonRegex.get_Type () [0x00000] in <filename unknown>:0
 
 at Parse.PlatformHooks+<RunDispatcher>d__44.MoveNext () [0x00000] in <filename unknown>:0
 
 at System.Nullable`1[System.DateTimeOffset].ToString () [0x00000] in <filename unknown>:0
 
 System.Nullable`1:ToString()
 
 UnityEngine.Debug:Internal_LogException(Exception, Object)
 
 UnityEngine.Debug:LogException(Exception)
 
 Parse.<RunDispatcher>d__44:MoveNext()

 System.Nullable`1:ToString()

The problem just appeared with the new Unity Parse SDK 1.5 (which contains the PNS feature). What we know is that running an empty project with just the parse sdk goes fine and the notifications work just fine, but in our actual project, because of the exception, devices dont register for the notifications in parse, so we are assuming there is a kind of a conflict between parse and one of the other tools we are using.

FYI : We are building the game using IL2CPP for a universal architecture (we re also building with .Net 2.0 subset, but I dont think that this has something to do with the problem).

Thank you for your time and for your answers.

UPDATE 1 ::

We tried to build using Mono(2.x) this time and we have pretty much the same exception that turned into this :

 ExecutionEngineException: Attempting to JIT compile method
 
 'System.Reflection.MonoProperty:StaticGetterAdapterFrame<int>
 
 (System.Reflection.MonoProperty/StaticGetter`1<int>,object)' while running with ­­aot­only.
 
 at System.Reflection.MonoProperty.GetValue (System.Object obj, System.Object[] index)
 
 [0x00000] in <filename unknown>:0
 
 at Parse.ParseInstallation.get_Badge () [0x00000] in <filename unknown>:0
 
 at Parse.ParseInstallation.SetPlatformAutomaticValue () [0x00000] in <filename
 
 unknown>:0
 
 at Parse.ParseInstallation.SetAutomaticValues () [0x00000] in <filename unknown>:0
 
 at Parse.ParseInstallation.SaveAsync (System.Threading.Tasks.Task toAwait,
 
 CancellationToken cancellationToken) [0x00000] in <filename unknown>:0
 
 at Parse.ParseObject+<>c__DisplayClass18.<SaveAsync>b__17
 
 (System.Threading.Tasks.Task toAwait) [0x00000] in <filename unknown>:0
 
 at Parse.Internal.TaskQueue.Enqueue[Task] (System.Func`2 taskStart, CancellationToken
 
 cancellationToken) [0x00000] in <filename unknown>:0
 
 at Parse.ParseObject.SaveAsync (CancellationToken cancellationToken) [0x00000] in
 
 <filename unknown>:0
 
 at Parse.ParseObject.SaveAsync () [0x00000] in <filename unknown>:0
 
 at Parse.ParseInitializeBehaviour.<Awake>b__0 (System.Byte[] deviceToken) [0x00000] in
 
 <filename unknown>:0
 
 at Parse.PlatformHooks+<>c__DisplayClass24.<RegisterDeviceTokenRequest>b__22 ()
 
 [0x00000] in <filename unknown>:0
 
 at Parse.PlatformHooks+<RunDispatcher>d__44.MoveNext () [0x00000] in <filename
 
 unknown>:0
 
 UnityEngine.Debug:Internal_LogException(Exception, Object)
 
 UnityEngine.Debug:LogException(Exception)
 
 Parse.<RunDispatcher>d__44:MoveNext()

Hopes it bring you guys more details about the problem.

UPDATE 2 ::

We know exactly what causes the exception to happen and unfortunately we have no control over it, its when we register for notification, we do it this way :

 using NotificationServices = UnityEngine.iOS.NotificationServices;
 using NotificationType = UnityEngine.iOS.NotificationType;
 
 public class UpdateScript : MonoBehaviour
 {
     void Start ()
     {
         // Ask for permission for push notifications (Can Receive deviceToken)
         #if UNITY_IPHONE
         NotificationServices.RegisterForNotifications(
             NotificationType.Alert | 
             NotificationType.Badge | 
             NotificationType.Sound);
         #endif
     }
 }




Comment
Add comment · Show 2
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image JoshPeterson · May 29, 2015 at 11:46 AM 0
Share

I posted an answer on the SO question here: http://stackoverflow.com/questions/30507713/executionengineexception-error-at-ios-runtime-with-parse-com-sdk

Basically, this looks like an error in the Parse SD$$anonymous$$, you may want to see how this was expected to work, as it may require a different configuration.

avatar image DaMex · May 29, 2015 at 12:08 PM 0
Share

Yes thank you I just saw your answer and I'm actually trying to isolate the registration procedure from everything else in our code to try to have a better callstack or even maybe work around the exception till we figure out what it is about exactly

0 Replies

· Add your reply
  • Sort: 

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this Question

Answers Answers and Comments

3 People are following this question.

avatar image avatar image avatar image

Related Questions

IL2CPP Compiled Application's scripts not working 1 Answer

unity3d(5.3.0f4) app crash on IOS 1 Answer

This parameter has to be of type: [UNREGISTERED] 0 Answers

Why does IL2CPP replace the "new" with Activator.CreateInstance? 0 Answers

Generic virtual methods on IL2CPP: how it works? 1 Answer


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges