question

shouttree avatar image
shouttree asked

Unicorn Battle iOS build returns "GetAccountInfo Timed out after 10 seconds."

Hi, Anyone met this problem while running Unicorn Battle in iOS ?

There's no such error in Unity Editor mode when selecting standalone mode in build settings. But when I switched to ios build, I got this error in both Unity Editor and the ios app built with xcode.

The timed out api call is

GetPlayerCombinedInfo

PlayFabHttp.MakeApiCall("/Client/GetPlayerCombinedInfo",...)

and it fails to get response within 10 seconds from playfab. only when the buildsettings is set to ios.

I'm new to Playfab and I don't know what's wrong. I thought Unicorn Battle should run with no error since I searched and found no related results. Anybody with any idea would be appreciated.

Thanks.

unity3dAccount ManagementAuthentication
2 comments
10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Citrus Yan avatar image Citrus Yan commented ·

Hi @shouttree, can you provide network traffic details of the timed-out response using the network capture tool such as fiddler?

0 Likes 0 ·
shouttree avatar image shouttree Citrus Yan commented ·

Yes of course. But due to words limit, I'll reply directly to my question.

0 Likes 0 ·

1 Answer

·
shouttree avatar image
shouttree answered

Hi, Citrus

I used Charles to capture the network info since somehow I failed to install fiddler on my macbookpro.

When set to ios in Build Settings and run in Unity Editor, The requested info and the reponse content is in this text file:getplayercombinedinfo-failed-charlescontent.txt
When set to standalone in Build Settings and run in Unity Editor, The requested info and the reponse content is in this text file:getplayercombinedinfo-success-charlescontent.txt

You can see that there's no obvious difference between them. And it seems weird to fail since there's response from playfab for ios build.

I traced a bit further in Unity script of Unicorn battle, only to find that the Timed Out error message appears since the success callback(in the code below it's OnGetUserAccountInfoSuccess) is not called.

PlayFabClientAPI.GetPlayerCombinedInfo(request, OnGetUserAccountInfoSuccess, PF_Bridge.PlayFabErrorCallback);

For standalone build, though the response info is the same as the ios build, OnGetUserAccountInfoSuccess is called and there's no such error message after then.

Do you know why there's such difference for the two platform even they're all run in Unity Editor ? I didn't find the code to call the callback of MakeApiCall, I think it must be binary.

Appreciate for your help and look forward for your answer.

Thanks,

Shouttree


9 comments
10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Citrus Yan avatar image Citrus Yan commented ·

Hi @shouttree,

Which Unity version are you using? I am trying to reproduce it.

0 Likes 0 ·
shouttree avatar image shouttree Citrus Yan commented ·

2019.1.3f1, it's the version the latest master branch of Unicorn Battle uses.

0 Likes 0 ·
Citrus Yan avatar image Citrus Yan commented ·

And, does it help if you upgrade PlayFab SDK to the newest version?

0 Likes 0 ·
shouttree avatar image shouttree Citrus Yan commented ·

I tried it, but after upgrading there're some compiling errors which I don't know how to fix.

0 Likes 0 ·
Citrus Yan avatar image Citrus Yan shouttree commented ·

Hi @shouttree, just discussed with the team, it might be a transport layer issue in Unity when switching to IOS build. Actually, Unicorn Battle is a rather complex sample, which is hard to debug. Here are some samples demonstrating PlayFab features, you can start from that.

0 Likes 0 ·
Show more comments

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.