question

fischp avatar image
fischp asked

Upgrading to Unity 2017

My team has just upgraded to Unity2017. Is there a compatible Playfab SDK for this, or should we change the directives in the SDK to UNITY_2017 instead of UNITY_5?

10 |1200

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

1807605288 avatar image
1807605288 answered

[UPDATE]

  • Once again, UnityWWW is the best, and default choice for your requestType setting. In fact, HttpWebRequest was discovered to be insecure, so it's been disabled.
  • Compression should work again, we encourage everybody to enable it, and test it out.
  • We believe that the .Net 4.6 runtime should also work with UnityWWW and UnityWebRequest

[Original]

The latest release of Unity has multiple regressions when it comes to WWW response headers. This has had a negative impact on our service, and our UnitySDK.

We're building several workarounds that will make it more stable. Ultimately, we can't fully resolve the issue until Untiy fixes the issue on their end.

In the meantime, here's the list of things you can try:

  • In the PlayFab settings, switch the requestType from UnityWWW to HttpWebRequest
  • In the PlayFab settings, disable compression
  • Don't use .Net 4.6 runtime (yet)
    • It's quite possible that no combination of settings in our SDK works with .Net 4.6 at this time

We're working on making all combinations stable, but the number of combinations is growing, old "working" combinations are breaking with new Unity versions, and it's becoming a larger and larger test grid overall. Apologies, please bear with us.

10 |1200

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

brendan avatar image
brendan answered

I can see the confusion - I'll get the tools team to update the Unity SDK picture on the SDK pages. :)

Our Unity SDK is fully compatible with 2017. To be clear, we haven't completed testing with 2017.2 yet, but we don't see any reason it would have issues. If you do run into any, please be sure to let us know.

10 |1200

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

zymakenneth avatar image
zymakenneth answered

@Brendan Has this been tested yet? I am running into problems with the following setup:

Unity 2017.2.0f3

Playfab SDK 2.23.171106

Not sure if something changed with Unity's Get response Headers. However, hard crash on Android build attempting to simply call Login with google account. I have not found a workaround (had to rip out Playfab for the time being).

I am also seeing the login request on my playfab dashboard and an error for "invalid params". I double checked that I am sending the server auth code and title ID.

E/CRASH ( 3406): signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 00000000 E/CRASH ( 3406): *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** E/CRASH ( 3406): Build fingerprint: 'samsung/gtexswifixx/gtexswifi:5.1.1/LMY47V/T280XXU0AQA4:user/release-keys' E/CRASH ( 3406): Revision: '5' E/CRASH ( 3406): pid: 3406, tid: 3423, name: UnityMain >>> com.Zyma.AlphaBuild <<< E/CRASH ( 3406): r0 00000000 r1 910950a0 r2 8706a210 r3 00000000 E/CRASH ( 3406): r4 a06d9c10 r5 a16d691c r6 00000000 r7 8706dcf0 E/CRASH ( 3406): r8 00000000 r9 00000226 sl 00000002 fp a16d6528 E/CRASH ( 3406): ip a16d6478 sp a16d6528 lr af45db2c pc 9d6b5888 cpsr 34594d4c E/CRASH ( 3406): E/CRASH ( 3406): backtrace: E/CRASH ( 3406): #00 pc 00005888 ( UnityEngine.WWW:get_responseHeaders () + 0xf0 (0x9d6b5798 0x9d6b58a0) [0xaf46fee0 - Unity Root Domain]+22664) E/CRASH ( 3406): #01 pc 00002b28 ( string:CharCopy (char*,char*,int) + 0x90 (0xaf45da98 0xaf45db34) [0xaf46fee0 - Unity Root Domain]+11048)

4 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.

brendan avatar image brendan commented ·

Can you provide the details of the Title ID you're using for this test, and can you try making the call in Postman and provide the complete response body? Meanwhile, I'll have the tools team check on the status of testing on 2017.2.

1 Like 1 ·
brendan avatar image brendan brendan commented ·

Actually, since I see you also posted the crash info as a separate question, I'll have them follow-up there. For this thread, can you just provide the specifics on the LoginWithGoogleAccount call?

1 Like 1 ·
1807605288 avatar image 1807605288 ♦ commented ·

There was a similar regression with the Unity WWW response headers very recently, which we bypassed. This seems to be another iteration of it.

We can't fix, or do anything about a crash in the Unity engine itself. Please provide that crash dump to Unity.

0 Likes 0 ·
1807605288 avatar image 1807605288 ♦ 1807605288 ♦ commented ·

You can change your PlayFab settings from UnityWWW to HttpWebRequest, to bypass this problem, but we're ALSO aware of some long-term performance problems for that mode, if the program runs for more than 24 hours. Any application running in HttpWebRequest needs to be restarted periodically.

0 Likes 0 ·
ignat-nee avatar image
ignat-nee answered

Greetings @Brendan!
Today i'm install unity 2017.2.03f, and try to build empty android application with Playfab (Sdk version is 2.32.171106). When i'm call LoginWithPlayFab function, it's crashed on .Net 4.6 runtime with fingerprint

I/DEBUG   (  337): Build fingerprint: 'Xiaomi/ido/ido:5.1.1/LMY47V/V7.3.2.0.LHPCNDD:user/release-keys'
I/DEBUG   (  337): Revision: '0'
I/DEBUG   (  337): ABI: 'arm'
I/DEBUG   (  337): pid: 20425, tid: 20470, name: UnityMain  >>> com.Company.ProductName223 <<<
I/DEBUG   (  337): signal 11 (SIGSEGV), code 0 (SI_USER), fault addr 0x0
I/DEBUG   (  337):     r0 00000000  r1 de5cbd60  r2 e28ee720  r3 00000000
I/DEBUG   (  337):     r4 e2815b9c  r5 e342395c  r6 e34238b0  r7 de5c2e20
I/DEBUG   (  337):     r8 aba221d0  r9 00000040  sl 00000002  fp e3423330
I/DEBUG   (  337):     ip e2815ce0  sp e34232f8  lr e26fbee0  pc de533158  cpsr 80000010
I/DEBUG   (  337):
I/DEBUG   (  337): backtrace:
I/DEBUG   (  337):     #00 pc 0005d158  <unknown>
I/DEBUG   (  337):     #01 pc 003a8edc  /data/app/com.Company.ProductName223-1/lib/arm/libmonobdwgc-2.0.so (mono_tls_get_thread+24)

But it's works fine with stable net runtime 3.5f version.
Did you know about this bug?

6 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.

brendan avatar image brendan commented ·

Thanks, based on the feedback so far (both this thread and https://community.playfab.com/questions/15741/unity-2017-fatal-error-on-android-get-response-hea.html), it sounds like there may be some problems with the 2017.2.03f version of Unity. Our tools team is checking to see if there are compatibility issues, but I'd have to recommend not updating to that version currently.

0 Likes 0 ·
ignat-nee avatar image ignat-nee brendan commented ·

If you can, could you suggest the approximate time of waiting new version of playfab with fixes?
It's important for us to know approximate date to decide, should we override our project to previous unity version, or just waiting for playfab fixes.

1 Like 1 ·
brendan avatar image brendan ignat-nee commented ·

Our tools team is looking into this, and we'll be able to provide an update next week, once they've had a chance to review.

0 Likes 0 ·
Show more comments
1807605288 avatar image 1807605288 ♦ commented ·

Hi ignat-nee.

We haven't yet had the chance to do thorough testing with .Net 4.6 runtime. We were unaware of a problem, but clearly you've demonstrated one.

We have slated some time to do some basic investigation with .Net 4.6 this month, so we'll try to get it fixed.

Thanks

0 Likes 0 ·

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.