Start a new topic
Answered

Swift 3.0.2 rejecting Kinvey 3.3.5

I'm starting a new Xcode project for this app and am using Kinvey 3.3.5 for the first time. I'm getting two errors with Swift 3.0.2:

(1) The PromiseKit now has a critical buildtime error for private class KVOProxy saying that the private override func observeValue should be 'fileprivate' instead of 'private'. It's a simple change, but this is a locked framework file so I cannot/should not make that change, so I'm asking for your advice.

(2) When I try 'import Kinvey', it complains saying that a Module compiled with Swift 3.0 cannot be imported in Swift 3.0.2.

I am unable to build my app at all because of the above two problems.



Best Answer

Isuru,


I was able to fix my issue, hopefully my solution will fix yours too.


I started from scratch and removed all references of Kinvey then installed the latest Kinvey SDK manually, rather than using CocoaPods.  I also had to add a required module via CocoaPods:  pod 'XCGLogger', '~> 4.0.0'


After adding the Kinvey frameworks to my project, I also had to my app Targets > General tab and add all the Kinvey frameworks to both "Embedded Binaries" and "Linked Frameworks and Libraries".


Now everything builds and runs for me.   Hope this helps.


1 person has this question

I'm experiencing the same issue #2 as you are:

 

Module compiled with Swift 3.0 cannot be imported in Swift 3.0.2: /Users/....../Pods/Kinvey/Kinvey-3.3.0/Kinvey.framework/Modules/Kinvey.swiftmodule/x86_64.swiftmodule

Anyone able to solve this issue?

Isuru,


  1. What version of Xcode are you using?
  2. Can you let me know what this project setting “Use Legacy Swift Language Version” is set to?
  3. If you set “Use Legacy Swift Language Version” of Realm and your project to NO - does that make a difference?


Thanks,

Pranav

Kinvey

1. Version 8.2.1

2. It is set to 'NO' for the Target and 'Unspecified' for the Project

3. If I set it to 'NO' for the Project (instead of 'Unspecifed'), it makes no difference. 

Answer

Isuru,


I was able to fix my issue, hopefully my solution will fix yours too.


I started from scratch and removed all references of Kinvey then installed the latest Kinvey SDK manually, rather than using CocoaPods.  I also had to add a required module via CocoaPods:  pod 'XCGLogger', '~> 4.0.0'


After adding the Kinvey frameworks to my project, I also had to my app Targets > General tab and add all the Kinvey frameworks to both "Embedded Binaries" and "Linked Frameworks and Libraries".


Now everything builds and runs for me.   Hope this helps.

That worked perfectly Chris!! Thank you so much!!

I'm glad that worked for you, Isuru.


However, I don't think this should be a permanent solution.  I believe a new Kinvey SDK needs to be built using the latest Xcode 8.2.1 and Swift 3.0.2 and released to CocoaPods.

Absolutely!

Completely agree

Login or Signup to post a comment