question

Evan avatar image
Evan asked

iOS Objective-C SDK issues

I just downloaded the latest iOS SDK and am attempting to work with it for the first time (I've previously been working with the Windows C++ SDK and native Android SDK successfully.

The first issue I've run into is that the code doesn't seem to compile. Building the "PlayFab ObjC Test" project results in a bunch of compile errors like this:

Objective_C_SDK/PlayFabSDK/PlayFabClientDataModels.h:3167:46: error: interface type cannot be statically allocated@property GetPlayerCombinedInfoRequestParams InfoRequestParameters

Resulting from a bunch of properties defined as returning non-pointer instances of NSObject derived types. I bisected the problem in the git repo to this commit:

https://github.com/PlayFab/Objective_C_SDK/commit/9ad0a718c46434a3756bbfc7044daaf855edf51a

So it seems it's been broken for almost 2 years.

If I fix the errors (by changing all the affected properties to return pointer types) then I'm able to build and run my application. However any login request I try to make through the Objective-C API never returns any result. After hanging for a minute I'll see messages like this in the output Window:

2018-06-05 19:22:20.220427-0700 MyAppName[296:188717] [BoringSSL] Function nw_protocol_boringssl_input_finished: line 1386 Peer disconnected during the middle of a handshake. Sending errSSLFatalAlert(-9802) alert

2018-06-05 19:22:20.233022-0700 MyAppName[296:188717] TIC TCP Conn Failed [1:0x1070cb520]: 3:-9802 Err(-9802)

2018-06-05 19:22:20.235665-0700 MyAppName[296:188717] NSURLSession/NSURLConnection HTTP load failed (kCFStreamErrorDomainSSL, -9802)

2018-06-05 19:22:20.236047-0700 MyAppName[296:188717] Task <0EF03B86-7009-41AA-9257-78EB243C3E39>.<0> HTTP load failed (error code: -1200 [3:-9802])

2018-06-05 19:22:20.241026-0700 MyAppName[296:188807] NSURLConnection finished with error - code -1200

So it seems like this SDK is not in very good shape, are there plans to release a new version anytime soon?

10 |1200

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

1 Answer

·
1807605288 avatar image
1807605288 answered

I have forwarded this issue to the engineer who is taking over the ObjectiveC SDK. I have asked him to post his own response here as well.

Obviously, those commits come from me, so apologies. I'm not an expert with ObjC, and so I'm happy to tell you that somebody better is taking over that project, and will bring it back to a sane place.

Sorry for the state of that SDK, it's totally my fault, but we've got a better guy who's going to improve it soon.

As a first step, while the new team member ramps up, can you please provide a pull request that fixes the issue you talk about? And our new team member can ramp up and give you an answer about the final problem you're experiencing, and hopefully get you working.

Apologies, and thanks in advance.

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.

Evan avatar image Evan commented ·

Hi Paul,

No worries, it was just a little surprising that apparently nobody (including users!) seemed to have used this SDK since 2016 :-D

I managed to get past the connection issue as well and everything is working fine in our project now. I've made a pull request with both fixes (and a note about a possible third one) here https://github.com/PlayFab/Objective_C_SDK/pull/14.

Thanks!

Evan

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

I agree with you!

For ttransparency, our internal testing doesn't currently cover ObjC SDK, so we would have relied on a customer report to find this issue, such as the one you sent.

Thanks for the pull request! I'll make it a priority to get that reviewed quickly.

This SDK is still built by our Generator, so we'll try to port that over there for you.

Thanks again!

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.