Skip to main content

Hello!

I have an app working perfectly and it's time to implement purchases in it through Revenuecat.

However when I install the react-native-purchases library several errors related to Swift are displayed (both when I try from the console and from XCode).

The RN version I'm running is 0.63.4, Xcode 13.0 and I'm testing it in simulators/devices with IOS 15.

Are there any known incompatibilities with these versions?

Some errors I get when trying to compile:

  • Undefined symbol: protocol conformance descriptor for Swift.UInt8 : Swift.FixedWidthInteger in Swift
  • Undefined symbol: protocol descriptor for Foundation.LocalizedError
  • Undefined symbol: method descriptor for Foundation.LocalizedError.errorDescription.getter : Swift.String?
  • Undefined symbol: method descriptor for Foundation.LocalizedError.failureReason.getter : Swift.String?
  • Undefined symbol: (extension in Foundation):Foundation.LocalizedError.recoverySuggestion.getter : Swift.String?
  • Undefined symbol: (extension in Foundation):Foundation.LocalizedError.failureReason.getter : Swift.String?

(and a lot more, about 100).

Any suggest for help me to use Revenuecat in my project?

(When I uninstall the library all back to works fine)

Thanks for all for your attention!

Hey @Daniel Pimentel :wave: ,

When looking at our docs for the Additional setup required for IOS for React Native which option are you using? Installing with Cocoapods / ExpoKit (with Auto-linking) , Installing with Cocoapods / ExpoKit (Manual linking only) or Manually adding the framework (if you're not using Cocoapods)?

 

 


Hello!

After a few days stucked I simple add a empty swift file on my project and everything works fine!


Can you elaborate on how to create this dummy swift file and where to put it? 

I read in the React Native SDK installation guide :

 

 

Swift Support

If your project has no Swift files or Swift support is disabled for the project, you will need to enable Swift support. The easiest way to do it is to add a single, empty Swift file.

 

But not a clue on how to do this. Thanks


I have same issue here is it possible to get a fix for this, i have tried selected answer method, which is creating new file but it didn’t work, still same issue. 

 


Hello,

 

@Rishi Siva I’m having the exact same issue as you. Did you manage to solve it?

Thank you.


Hello,

 

@Rishi Siva I’m having the exact same issue as you. Did you manage to solve it?

Thank you.

No this issue still happening to me, but it works fine with bare react native project not with existing code, im re-running all the modules ill give an update in a while.


Hello,

 

@Rishi Siva I’m having the exact same issue as you. Did you manage to solve it?

Thank you.

No this issue still happening to me, but it works fine with bare react native project not with existing code, im re-running all the modules ill give an update in a while.

I just discovered that running version 4.x of react-native-purchases is working for me. Can’t install 5.X no clue why.


I to am having the same issues (undefined symbols) when trying to archive my project… I have tried removing pods and running pod install, updating my version of RN, upgraded and downgraded to try different versions of react-native purchases but to no avail. 

If anyone could help with a solution to this it would be greatly appreciated.


For anyone struggling with this issue - This solved it for me (the order has to be the same as the screenshot)…. https://github.com/RevenueCat/react-native-purchases/issues/341


Reply