triniwiz / nativescript-plugins

Apache License 2.0
80 stars 50 forks source link

[ socket.io-client-swift ] - pod install error #51

Closed Ed-Simmons closed 3 years ago

Ed-Simmons commented 3 years ago

Hello, I'm getting the following error when trying to do a clean iOS build (NS 7, iOS runtime v6.5.4):

[!] CocoaPods could not find compatible versions for pod "Socket.IO-Client-Swift":
  In Podfile:
    Socket.IO-Client-Swift (from `https://github.com/triniwiz/socket.io-client-swift.git`)

Specs satisfying the `Socket.IO-Client-Swift (from `https://github.com/triniwiz/socket.io-client-swift.git`)` dependency were found, but they required a higher minimum deployment target.

Any thoughts on how to resolve this?

Ed-Simmons commented 3 years ago

I found a solution:

By including a Podfile in the App_Resources/iOS folder, you can force the target version to be higher than NativeScript's default of (I think) 8, like so:

platform :ios, '10.0'

Is this not a bit concerning for backwards compatibility though? Why was this necessary in the first place?

triniwiz commented 3 years ago

They bumped the version

Ed-Simmons commented 3 years ago

OK that makes sense! Interestingly I'm only getting this bug/ error message on a project that explicitly states a deployment target. If there is none given, the pod install has no errors.

However, this line now appears in my console every time I open the app:

TypeError: this.socket.connect is not a function
triniwiz commented 3 years ago

I added the platform version to the plugin but are you still getting the following ?

TypeError: this.socket.connect is not a function
Ed-Simmons commented 3 years ago

I'm no longer getting that message :)