Closed laud closed 8 years ago
Is this still an issue in the latest Xcode beta? I have been build the SDK for iOS 10 periodically and haven't run into this issue. Since I develop using the demo project, I thought there might be an issue with Cocoapods and/or using Swift but I just tested it and it seems fine.
@kkarayannis yes I still have this problem. As @laud said above, the issue is not with iOS 10, but when you run the code compiled by XCode 8 on to an iOS 9 device it crashes with this error:
dyld: Symbol not found: _kABPersonAddressCityKey
Referenced from: /private/var/containers/Bundle/Application/1ED5CB2D-CE95-411B-A907-C7B381C798FF/EsplorioDebug.app/Frameworks/Kite_Print_SDK.framework/Kite_Print_SDK
Expected in: /System/Library/Frameworks/PassKit.framework/PassKit
in /private/var/containers/Bundle/Application/1ED5CB2D-CE95-411B-A907-C7B381C798FF/EsplorioDebug.app/Frameworks/Kite_Print_SDK.framework/Kite_Print_SDK
is there any updates on this?
OK, I was able to reproduce this. As you said @famanson, it only happens at runtime on an iOS 9 device, and it only happens when building with frameworks.
I will migrate to the new Contacts framework over the next few days, though iOS 8 will keep using the old code because Contacts was introduced with 9. I don't have an iOS 8 device to test though, so the issue might persist there (although if it does I'm not sure what can be done).
Until I make the changes you can disable Apple Pay by removing the subspec:
#pod 'Kite-Print-SDK/ApplePay'
@kkarayannis cool, thanks
OK this issue is now fixed in the latest version, 5.4.0
@kkarayannis thanks, gonna give this one a go
@kkarayannis Hi, we have the same issue with our SDK. Could you please share how you fixed it? Right now the workaround seems to be removing and readding the Addressbook and PassKit frameworks.
Unfortunately I didn't find a solution that would work with Addressbook, so I replaced all the functionality with the new Contacts framework. We only used it to read the shipping address when a user paid with Apple Pay so it wasn't a lot of work. The downside of this approach is that we no longer offer Apple Pay to iOS 8 users, since Contacts was introduced in iOS 9.
@kkarayannis thanks for the quick reply. We're also only using it to save a contact, so it's not a big deal to switch over to the Contacts framework. We'll consider dropping iOS 8 support. Thanks!
Hi is there any update on this issue. i am using PaySafe SDK which internally uses AddressBook. i am not able run application below iOS 10.
yld: Symbol not found: _kABPersonAddressCityKey Referenced from: /Users/ajitemsahasrabuddhe/Library/Developer/CoreSimulator/Devices/83287726-DAB4-4319-9950-B4750F56DFAD/data/Containers/Bundle/Application/EB937A70-7404-49AA-966F-DF19720D824A/ChangeTransit.app/Frameworks/Paysafe.framework/Paysafe Expected in: /Library/Developer/CoreSimulator/Profiles/Runtimes/iOS 9.1.simruntime/Contents/Resources/RuntimeRoot/System/Library/Frameworks/PassKit.framework/PassKit in /Users/ajitemsahasrabuddhe/Library/Developer/CoreSimulator/Devices/83287726-DAB4-4319-9950-B4750F56DFAD/data/Containers/Bundle/Application/EB937A70-7404-49AA-966F-DF19720D824A/ChangeTransit.app/Frameworks/Paysafe.framework/Paysafe
We do not have PaySafe as a dependency in our SDK. This issue has been fixed in our SDK for a while now.
What you did to fix this issue. have you replaced Addressbook implementation with Contacts framework?
Yeah exactly, there can be no reference of Addressbook constants at compile time when targeting iOS 8 or earlier and using PassKit, or it crashes on launch. iOS 9+ should be safe.
Thanks for quick reply & co-operation.
AddressBook framework was deprecated in iOS 9. When trying to run an app with Print SDK, the app crashes because lack of AddressBook symbols. This exception appears only an app is built on iOS 10, but running on a iOS 9 or less device.
I recommend migrating to Contacts framework and/or have preprocessor macros that don't include the AddressBook framework code when built on iOS 10.