[NSStream getStreamsToHostNamed:port:inputStream:outputStream:]: unrecognized selector sent to class

Post here your questions about the Objective-C API for SFS2X

Moderators: Lapo, Bax

mmilen
Posts: 213
Joined: 09 Nov 2010, 00:48
Contact:

[NSStream getStreamsToHostNamed:port:inputStream:outputStream:]: unrecognized selector sent to class

Postby mmilen » 07 Oct 2018, 14:17

Hi ,

I'm running into trouble with XCode 10. My Shark Bridge App for iOS runs great when build with XCode 9, but with XCode 10 I get this error : [NSStream getStreamsToHostNamed:port:inputStream:outputStream:]: unrecognized selector sent to class

I'm using the latest SartFOx 2X and the latest Objective-C API.
User avatar
Lapo
Site Admin
Posts: 20436
Joined: 21 Mar 2005, 09:50
Location: Italy

Re: [NSStream getStreamsToHostNamed:port:inputStream:outputStream:]: unrecognized selector sent to class

Postby Lapo » 08 Oct 2018, 09:13

Hi,
we have not tested XCode 10 yet. We'll setup a machine and check it out.
In any case it looks like that NSStream method has been removed from the OS. It's marked as deprecated in the docs though there's no indication for an alternative.

I'll post our progresses after we have investigated.
Thanks for the feedback.
Lapo
--
gotoAndPlay()
...addicted to flash games
User avatar
Lapo
Site Admin
Posts: 20436
Joined: 21 Mar 2005, 09:50
Location: Italy

Re: [NSStream getStreamsToHostNamed:port:inputStream:outputStream:]: unrecognized selector sent to class

Postby Lapo » 08 Oct 2018, 14:32

UPDATE:
after some digging in the Apple docs we've found a possible solution that should work for all platforms.
Since we don't have a machine ready with High Sierra/Mojave + XCode 10 it would be probably quicker if you could test it.

Meanwhile we'll set up a proper environment to prepare the final release.
If you want to test it out quickly, drop us an email to our support@... mail address with a reference to this thread.

Hope it helps.
Lapo

--

gotoAndPlay()

...addicted to flash games
mmilen
Posts: 213
Joined: 09 Nov 2010, 00:48
Contact:

Re: [NSStream getStreamsToHostNamed:port:inputStream:outputStream:]: unrecognized selector sent to class

Postby mmilen » 09 Oct 2018, 21:21

After installing Additional Tools for XCode 10.1 Beta 2 from Sept 27th, all is working well. I'm on High Sierra. Apple had broken a number of 3rd party frameworks with the initial release of XCode 10.
User avatar
Lapo
Site Admin
Posts: 20436
Joined: 21 Mar 2005, 09:50
Location: Italy

Re: [NSStream getStreamsToHostNamed:port:inputStream:outputStream:]: unrecognized selector sent to class

Postby Lapo » 10 Oct 2018, 07:50

That's interesting. I tested under XCode 10.0 and had the same problem.
It seems to be connected with the deprecation of the method you have mentioned, though the apple doc doesn't say anything about the method being removed.

So they probably just messed it up. In any case we've now implemented a solution that doesn't depend on the deprecated method and works on XCode 10.0 as well.
We'll release it in the next few days.

Cheers
Lapo

--

gotoAndPlay()

...addicted to flash games
User avatar
Lapo
Site Admin
Posts: 20436
Joined: 21 Mar 2005, 09:50
Location: Italy

Re: [NSStream getStreamsToHostNamed:port:inputStream:outputStream:]: unrecognized selector sent to class

Postby Lapo » 12 Oct 2018, 13:53

The API 1.7.6 has been released:
https://www.smartfoxserver.com/download/sfs2x#p=client

Cheers
Lapo

--

gotoAndPlay()

...addicted to flash games

Return to “SFS2X iPhone / iPad / OSX API”

Who is online

Users browsing this forum: No registered users and 1 guest