-
Notifications
You must be signed in to change notification settings - Fork 264
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
OneSignalNotificationServiceExtension bitcode error on build #659
Comments
@Style87 +1, did you manage to figure this out ? |
@Graig123git, unfortunately I have not. I've been at this error off and on for a weeks now. |
It looks like bitcode is still enabled somewhere. The problem arises since the app was compiled without bitcode. Make sure it is set to No in both the project and library settings |
Is it possible that grepping my entire code base from the root for BITCODE would not show an instance where it's set to yes? I have done this and every value is set to no. |
How about you guys, this error is really a headache since a few days ago everything was working fine for me but suddenly I threw myself that error when trying to subscribe the user. Today I managed to find a solution or at least make it work. Steps to follow:
pod repo update
then in the root folder of your project run again
in my case as I am working with ionic, enable onesignal debugging options, building an object of each persimo that requests onesignal this.oneSignal.startInit('#####', ####');
//important debuggin info
this.oneSignal.setLogLevel({logLevel: 6, visualLevel: 0});
this.oneSignal.inFocusDisplaying(this.oneSignal.OSInFocusDisplayOption.Notification);
this.oneSignal.handleNotificationReceived().subscribe((respNoti) => {
// do something when notification is received
});
this.oneSignal.handleNotificationOpened().subscribe((respNoti) => {
// do something when a notification is opened
});
this.oneSignal.getIds().then(info => {
this.userId = info.userId;
this.userToken = info.pushToken;
console.log('ID OneSignal: ',this.userId);
console.log('Token push: ', this.userToken);
});
this.oneSignal.endInit(); //function get log status user (debug for safari) getStatusUser() {
this.oneSignal.getPermissionSubscriptionState().then((resp:OSPermissionSubscriptionState) => {
let Obj:any = {
Promt: resp.permissionStatus.hasPrompted,
PermisosIOS: resp.permissionStatus.status,
PermisosAnd: resp.permissionStatus.state,
Suscrito: resp.subscriptionStatus.subscribed,
ConfigUser: resp.subscriptionStatus.userSubscriptionSetting,
UserID: resp.subscriptionStatus.userId,
UserToken: resp.subscriptionStatus.pushToken
}
console.log('OneDebug: ',Obj);
console.log('iOS: 0 = Not Determined, 1 = Denied, 2 = Authorized ', resp.permissionStatus.status);
console.log('Android: 1 = Authorized, 2 = Denied ', resp.permissionStatus.state);
console.log('FCM/APNs: ', resp.subscriptionStatus.pushToken);
})
} then proceed to generate project build again to know if your push subscription was successful the userId and pushToken must contain a string of strings must not be null basically the problem is fixed when updating cocoa pods. |
Thank you for the solution! I will close this issue. Cheers |
The solution did not help with flutter |
I'm getting this in Flutter too. @rgomezp should we reopen this issue? |
Howdy @nomicool @robertohuertasm Before reopening here, would you please take a look at this Flutter-specific thread and try the suggestions from there? |
for Unity, check this thread: OneSignal/OneSignal-Unity-SDK#540 (comment) |
Description:
When I go to build to my target device I get the error below.
ld: '/Users/lucashartzell/Library/Developer/Xcode/DerivedData/Runner-dpeadbdaauvfpbgyhkflubgrwpbm/Build/Products/Debug-iphoneos/libPods-OneSignalNotificationServiceExtension.a(Pods-OneSignalNotificationServiceExtension-dummy.o)' does not contain bitcode. You must rebuild it with bitcode enabled (Xcode setting ENABLE_BITCODE), obtain an updated library from the vendor, or disable bitcode for this target. file '/Users/lucashartzell/Library/Developer/Xcode/DerivedData/Runner-dpeadbdaauvfpbgyhkflubgrwpbm/Build/Products/Debug-iphoneos/libPods-OneSignalNotificationServiceExtension.a' for architecture arm64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
I have bitcode_enabled set to no everywhere it can be. I've looked through all the values in Xcode and I've greped for it in the code base to confirm so.
Environment
iOS 13.4 -sdk iphoneos13.4
The one signal sdk was added through cocoapods. The onesignal_flutter version in the pubspec is 2.3.4.
Steps to Reproduce Issue:
Anything else:
I have already tried running flutter clean and doing a full reinstall on the pods with no luck.
Podfile.txt
The text was updated successfully, but these errors were encountered: