walterholohan / react-native-crisp-chat-sdk

React-Native bridge for Crisp Chat iOS and Android SDK's
MIT License
70 stars 26 forks source link

[IOS] Headers not found #109

Closed Matteo-Peronnet closed 1 year ago

Matteo-Peronnet commented 1 year ago

Hello,

I have a problem with version 0.11.0 with the chat opening only 50% of the time.

It has been mentioned here https://github.com/walterholohan/react-native-crisp-chat-sdk/issues/105#issue-1619960031. However after updating to version 0.13.1 which is supposed to fix the problem, I can't build the project anymore.

I have an error "'Crisp/Crisp-Swift.h' file not found" since this update with the iOS SDK 2.2.0.

Here is my environment:

System:
    OS: macOS 13.1
    CPU: (12) x64 Intel(R) Core(TM) i7-9750H CPU @ 2.60GHz
    Memory: 63.39 MB / 16.00 GB
    Shell: 5.8.1 - /bin/zsh
  Binaries:
    Node: 14.18.1 - ~/.nvm/versions/node/v14.18.1/bin/node
    Yarn: 1.22.17 - ~/.nvm/versions/node/v14.18.1/bin/yarn
    npm: 6.14.15 - ~/.nvm/versions/node/v14.18.1/bin/npm
    Watchman: 2022.02.28.00 - /usr/local/bin/watchman
  Managers:
    CocoaPods: 1.11.2 - /usr/local/bin/pod
  SDKs:
    iOS SDK:
      Platforms: DriverKit 22.2, iOS 16.2, macOS 13.1, tvOS 16.1, watchOS 9.1
    Android SDK: Not Found
  IDEs:
    Android Studio: 2020.3 AI-203.7717.56.2031.7784292
    Xcode: 14.2/14C18 - /usr/bin/xcodebuild
  Languages:
    Java: 11.0.14.1 - /usr/bin/javac
  npmPackages:
    @react-native-community/cli: Not Found
    react: 18.2.0 => 18.2.0
    react-native: 0.71.3 => 0.71.3
    react-native-macos: Not Found
  npmGlobalPackages:
    *react-native*: Not Found
oliuradu commented 1 year ago

Same here, did you find a solution?

Matteo-Peronnet commented 1 year ago

Not yet, I have rollback on a previous version where the project compiles with the problem of the chat opening.

baptistejamin commented 1 year ago

Could you please try using the latest release?

the SDK got updated

enchorb commented 1 year ago

Getting the same issue after upgrading to 0.13.1 'Crisp/Crisp-Swift.h' file not found

baptistejamin commented 1 year ago

Can someone here bring a Zip file containing a sample containing the issue?

Seems we are not having the same issue here.

oliuradu commented 1 year ago

@baptistejamin, i am using expo sdk 48. and "react-native-crisp-chat-sdk": "^0.13.1",

These are my build properties:

[
        "expo-build-properties",
        {
          android: {
            compileSdkVersion: 33,
            targetSdkVersion: 33,
            buildToolsVersion: "33.0.0",
          },
          ios: {
            deploymentTarget: "14.0",
            useFrameworks: "static",
          },
        },
      ],

I can build the internal build without problems but when i try to build production i got this error:

image

This happens in 0.13.0 also.

baptistejamin commented 1 year ago

What Commend do you use to get the production build?

Baptiste Jamin

On 20 Mar 2023, at 14:05, Oliu Radu Tudor @.***> wrote:

@baptistejamin https://github.com/baptistejamin, i am using expo sdk 48. and "react-native-crisp-chat-sdk": "^0.13.1",

These are my build properties:

[ "expo-build-properties", { android: { compileSdkVersion: 33, targetSdkVersion: 33, buildToolsVersion: "33.0.0", }, ios: { deploymentTarget: "14.0", useFrameworks: "static", }, }, ], I can build the internal build without problems but when i try to build production i got this error:

https://user-images.githubusercontent.com/42614946/226347204-f6bd5c28-2b00-44d3-a484-1805deebd422.png This happens in 0.13.0 also.

— Reply to this email directly, view it on GitHub https://github.com/walterholohan/react-native-crisp-chat-sdk/issues/109#issuecomment-1476199658, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAGTRQ5FP6WH3BYODIXO6F3W5BIZZANCNFSM6AAAAAAV6LOINU. You are receiving this because you were mentioned.

oliuradu commented 1 year ago

What Commend do you use to get the production build? -- Baptiste Jamin On 20 Mar 2023, at 14:05, Oliu Radu Tudor @.***> wrote: @baptistejamin https://github.com/baptistejamin, i am using expo sdk 48. and "react-native-crisp-chat-sdk": "^0.13.1", These are my build properties: [ "expo-build-properties", { android: { compileSdkVersion: 33, targetSdkVersion: 33, buildToolsVersion: "33.0.0", }, ios: { deploymentTarget: "14.0", useFrameworks: "static", }, }, ], I can build the internal build without problems but when i try to build production i got this error: https://user-images.githubusercontent.com/42614946/226347204-f6bd5c28-2b00-44d3-a484-1805deebd422.png This happens in 0.13.0 also. — Reply to this email directly, view it on GitHub <#109 (comment)>, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAGTRQ5FP6WH3BYODIXO6F3W5BIZZANCNFSM6AAAAAAV6LOINU. You are receiving this because you were mentioned.

eas build -p ios --profile production --clear-cache

And this is the eas config for production

image

baptistejamin commented 1 year ago

Would you mind creating a sample project with Eas that contains the same issue?

With as well command used to build in local (as it works on your end)

Baptiste Jamin

On 20 Mar 2023, at 14:08, Oliu Radu Tudor @.***> wrote:

What Commend do you use to get the production build? -- Baptiste Jamin … <x-msg://5/#> On 20 Mar 2023, at 14:05, Oliu Radu Tudor @.***> wrote: @baptistejamin https://github.com/baptistejamin https://github.com/baptistejamin, i am using expo sdk 48. and "react-native-crisp-chat-sdk": "^0.13.1", These are my build properties: [ "expo-build-properties", { android: { compileSdkVersion: 33, targetSdkVersion: 33, buildToolsVersion: "33.0.0", }, ios: { deploymentTarget: "14.0", useFrameworks: "static", }, }, ], I can build the internal build without problems but when i try to build production i got this error: https://user-images.githubusercontent.com/42614946/226347204-f6bd5c28-2b00-44d3-a484-1805deebd422.png This happens in 0.13.0 also. — Reply to this email directly, view it on GitHub <#109 (comment) https://github.com/walterholohan/react-native-crisp-chat-sdk/issues/109#issuecomment-1476199658>, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAGTRQ5FP6WH3BYODIXO6F3W5BIZZANCNFSM6AAAAAAV6LOINU. You are receiving this because you were mentioned.

eas build -p ios --profile production --clear-cache

And this is the eas config for production

https://user-images.githubusercontent.com/42614946/226347968-191e0cb8-7a49-4ea2-80c2-dca18869e4ab.png — Reply to this email directly, view it on GitHub https://github.com/walterholohan/react-native-crisp-chat-sdk/issues/109#issuecomment-1476205141, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAGTRQ4RZQDBILLTL7APNCDW5BJFNANCNFSM6AAAAAAV6LOINU. You are receiving this because you were mentioned.

baptistejamin commented 1 year ago

You can send an email to baptiste@crisp.chat

oliuradu commented 1 year ago

@Matteo-Peronnet can you do that? please?

P.s do you use expo also?

Matteo-Peronnet commented 1 year ago

Yes I use expo in ejected version. But I don't build the project with EAS. I build as a standard react-native application with Xcode.

Is the problem related to Expo?

oliuradu commented 1 year ago

Using version 0.13 solve the problem.

Matteo-Peronnet commented 1 year ago

I confirm that I can build version 13.0 but I still have the problem of opening the chat on one of the two calls.

arcln commented 1 year ago

Hello,

I also had this problem and I fixed by importing crisp from a swift file.

Crisp.swift

import Foundation
import Crisp

@objc class Crisp : NSObject {
  @objc static func setup() {
    CrispSDK.configure(websiteID: "xxx");
  }
}

AppDelegate.mm

- #import "Crisp/Crisp-Swift.h"
+ #import "MyApp-Swift.h"

# in application:didFinishLaunchingWithOptions
- [CrispSDK setup]
+ [Crisp setup]
baptistejamin commented 1 year ago

Do you also use Expo?Sent from my iPhoneOn 22 Mar 2023, at 12:13, Arthur Chaloin @.***> wrote: Hello, I also had this problem and I fixed by importing crisp from a swift file. Crisp.swift import Foundation import Crisp

@objc class Crisp : NSObject { @objc static func setup() { CrispSDK.configure(websiteID: "xxx"); } } AppDelegate.mm

in application:didFinishLaunchingWithOptions

—Reply to this email directly, view it on GitHub, or unsubscribe.You are receiving this because you were mentioned.Message ID: @.***>

arcln commented 1 year ago

No, I only use react native (v0.71.4).

rdhox commented 1 year ago

I have the problem with the latest version, going back to the v0.11.0 make me able to build the application.

baptistejamin commented 1 year ago

Hello!

It seems headers where missing in the crisp-ios-sdk package this library is using. It should be solved by using react-native-crisp-chat-sdk v0.13.2 :)