Why StorageTest from SDK samples works on PC and Mac but do not on Android or iOS device?

0 votes

My platform is Unity3D/C#.
I started the sample with StorageTest script active. I've set some values to the Constant.cs class that I think are necesary and ran it on Mac and PC - it works fine. But it doesn't work neither on iPad nor on Android phone. Pressing a button on Android just shows the button pressing animation, on iOS however it crashes the app. I didn't change in any way the StorageTest script, just the Constant.cs.
Do I have to set up something else when I intend to run the app on device?

Here is the log that I get for one of the buttons in the sample:

08-20 18:37:05.126: I/Unity(6413): NullReferenceException: Object reference not set to an instance of an object
08-20 18:37:05.126: I/Unity(6413):   at System.Security.Cryptography.HMAC.Initialize () [0x00000] in <filename unknown>:0 
08-20 18:37:05.126: I/Unity(6413):   at System.Security.Cryptography.HMAC.HashCore (System.Byte[] rgb, Int32 ib, Int32 cb) [0x00000] in <filename unknown>:0 
08-20 18:37:05.126: I/Unity(6413):   at System.Security.Cryptography.HashAlgorithm.ComputeHash (System.IO.Stream inputStream) [0x00000] in <filename unknown>:0 
08-20 18:37:05.126: I/Unity(6413):   at com.shephertz.app42.paas.sdk.csharp.util.Util.ComputeHmac (System.String input, System.Byte[] key) [0x00000] in <filename unknown>:0 
08-20 18:37:05.126: I/Unity(6413):   at com.shephertz.app42.paas.sdk.csharp.util.Util.Sign (System.String secretKey, System.Collections.Generic.Dictionary`2 paramsList) [0x00000] in <filename unknown>:0 
08-20 18:37:05.126: I/Unity(6413):   at com.shephertz.app42.paas.sdk.csharp.storage.StorageService.FindDocumentsByQuery (System.String dbName, System.String collectionName, com.shephertz.app42.paas.sdk.csharp.storage.Query query, App42CallBack callBack) [0x00000] in <filename unknown>:0 
08-20 18:37:05.126: I/Unity(6413):   at StorageTest.OnGUI () [0x007a3] in D:\Unity
08-20 18:37:36.369: I/Unity(6413): onPause
 

 

 

asked Aug 20, 2014 in App42 Cloud API-BaaS by simion.nacu (15 points)

1 Answer

0 votes
 
Best answer

This error comes up if you have stripping level enabled in your app. If that is the case, please use  link.xml and put this under Assets folder. Set the stripping level to ByteCode.

Let me know if it helps.

Thanks

Ajay

answered Aug 20, 2014 by ajay123 (899 points)
selected Aug 22, 2014 by simion.nacu
It works, thank you!
Download Widgets
Welcome to ShepHertz Product line forum, where you can ask questions and receive answers from the community. You can also reach out to us on support@shephertz.com
...