How to resolve this error in xcode? - ios

I am building a Cordova Application in XCode, but I am getting the following error :-
CDVLocation.m 'Cordova/NSArray+Comparisons.h' file not found
cordova platform
Installed platforms: android 5.1.1, ios 4.0.1
Available platforms: amazon-fireos, blackberry10, browser, firefoxos, osx, webos
Mac-de-binov:icooltaxi binov$ cordova plugin
cl.rmd.cordova.dialoggps 0.0.2 "DialogGPS"
com.cordova.plugins.sms 0.1.9 "Cordova SMS Plugin"
cordova-plugin-whitelist 1.2.1 "Whitelist"
in.girish.datagram 0.1.0 "UDP Plugin"
org.apache.cordova.device 0.3.0 "Device"
org.apache.cordova.geolocation 0.3.12 "Geolocation"
org.apache.cordova.splashscreen 1.0.0 "Splashscreen"
How can I fix this issue?

Related

Ionic 3 iOS build and Upload failed due to Razorpay

I am facing the following issues while uploading the iOS build. The iOS version is 12.3
(Though it was working on 12.1)
Currently, it is showing an error while making the build:
Xcode version: 10.2.1 (10E1001)
Here is the plugin list I am using in my app
com.razorpay.cordova 0.16.1 "RazorpayCheckout"
cordova-android-support-gradle-release 3.0.0 "cordova-android-support-gradle-release"
cordova-plugin-browsertab 0.2.0 "cordova-plugin-browsertab"
cordova-plugin-camera 4.0.3 "Camera"
cordova-plugin-compat 1.2.0 "Compat"
cordova-plugin-device 1.1.7 "Device"
cordova-plugin-facebook4 2.5.0 "Facebook Connect"
cordova-plugin-file 6.0.1 "File"
cordova-plugin-file-transfer 1.7.1 "File Transfer"
cordova-plugin-filechooser 1.2.0 "File Chooser"
cordova-plugin-geolocation 4.0.1 "Geolocation"
cordova-plugin-inappbrowser 2.0.2 "InAppBrowser"
cordova-plugin-ionic-webview 1.2.1 "cordova-plugin-ionic-webview"
cordova-plugin-request-location-accuracy 2.3.0 "Request Location Accuracy"
cordova-plugin-splashscreen 4.1.0 "Splashscreen"
cordova-plugin-statusbar 2.4.2 "StatusBar"
cordova-plugin-whitelist 1.3.3 "Whitelist"
cordova-sqlite-storage 2.6.0 "Cordova sqlite storage plugin"
cordova.plugins.diagnostic 4.0.12 "Diagnostic"
ionic-plugin-keyboard 2.2.1 "Keyboard"
Install cordova plugin add com.razorpay.cordova#1.4.5
import <Razorpay-swift.h>
In project Setting: General> Frameworks, Libraries, and Embedded Content> Razorpay.framework to Embed and Signin or Embed without Signing

Ionic v1 Cordova "prefs:root=" non-public URL scheme ios app rejection

My app for iOS got rejected with the following error:
Guideline 2.5.1 - Performance - Software Requirements
Your app uses the "prefs:root=" non-public URL scheme, which is a private entity. The use of non-public APIs is not permitted on the App Store because it can lead to a poor user experience should these APIs change.
I have seen several issues opened on this subject for the native iOS app but not Cordova or Ionic. Is there a way to resolve this in Cordova? Ironically, the build that got reject has only a minor change that shows a number with 3 decimals instead of 2. Everything else is the same. Yet, it got rejected.
Below is the list of all the plugins I have:
card.io.cordova.mobilesdk 2.1.0 "CardIO"
cordova-android-support-gradle-release 0.0.2 "cordova-android-support-gradle-release"
cordova-plugin-actionsheet 2.3.3 "ActionSheet"
cordova-plugin-app-event 1.2.1 "Application Events"
cordova-plugin-camera 2.4.1 "Camera"
cordova-plugin-compat 1.2.0 "Compat"
cordova-plugin-datepicker 0.9.3 "DatePicker"
cordova-plugin-device 1.1.6 "Device"
cordova-plugin-dialogs 1.3.3 "Notification"
cordova-plugin-facebook4 1.9.1 "Facebook Connect"
cordova-plugin-file 4.3.3 "File"
cordova-plugin-file-transfer 1.6.3 "File Transfer"
cordova-plugin-google-analytics 1.8.3 "Google Universal Analytics Plugin"
cordova-plugin-googleplus 5.3.1 "Google SignIn"
cordova-plugin-inappbrowser 1.7.1 "InAppBrowser"
cordova-plugin-ionic-webview 1.2.1 "cordova-plugin-ionic-webview"
cordova-plugin-splashscreen 4.0.3 "Splashscreen"
cordova-plugin-statusbar 2.2.4-dev "StatusBar"
cordova-plugin-touchid 0.4.0 "Touch ID"
cordova-plugin-vibration 2.1.5 "Vibration"
cordova-plugin-whitelist 1.3.2 "Whitelist"
cordova-plugin-x-socialsharing 5.4.1 "SocialSharing"
cordova.plugins.diagnostic 3.7.1 "Diagnostic"
de.appplant.cordova.plugin.local-notification 0.8.5 "LocalNotification"
es6-promise-plugin 4.2.2 "Promise"
ionic-plugin-keyboard 2.2.1 "Keyboard"
phonegap-plugin-barcodescanner 7.0.0 "BarcodeScanner"
As #Paulw11 suggested -
Run grep -r -i 'prefs' ./* under the plugins directory
Find references to the prefs
Update the plugins.
No code changes required.
Rebuild it and submit the archive.
Note: You may have to update all the plugins. I would highly recommend making a backup of all the plugins before updating them.

Ionic build ios error code 65

While trying to build ios using ionic cordova build ios, I am getting the following error -
Error: Error code 65 for command: xcodebuild with args: -xcconfig,/Users/raihan/Downloads/quitch-app/platforms/ios/cordova/build-debug.xcconfig,-workspace,Quitch.xcworkspace,-scheme,Quitch,-configuration,Debug,-sdk,iphonesimulator,-destination,platform=iOS Simulator,name=iPhone SE,build,CONFIGURATION_BUILD_DIR=/Users/raihan/Downloads/quitch-app/platforms/ios/build/emulator,SHARED_PRECOMPS_DIR=/Users/raihan/Downloads/quitch-app/platforms/ios/build/sharedpch
I have searched through the net since a long time but can not find any solution.
My plugins list
com-sarriaroman-photoviewer 1.1.10 "PhotoViewer"
cordova-plugin-console 1.0.5 "Console"
cordova-plugin-device 1.1.4 "Device"
cordova-plugin-file 4.0.0 "File"
cordova-plugin-file-opener2 2.0.19 "File Opener2"
cordova-plugin-file-transfer 1.6.3 "File Transfer"
cordova-plugin-firebase 0.1.23 "Google Firebase Plugin"
cordova-plugin-network-information 1.3.3 "Network Information"
cordova-plugin-splashscreen 4.0.3 "Splashscreen"
cordova-plugin-statusbar 2.2.1 "StatusBar"
cordova-plugin-whitelist 1.3.1 "Whitelist"
cordova-plugin-youtube-video-player 1.0.6 "CordovaYoutubeVideoPlayer"
cordova-sqlite-storage 2.0.4 "Cordova sqlite storage plugin"
ionic-plugin-keyboard 2.2.1 "Keyboard"
My system info
cli packages:
#ionic/cli-plugin-cordova : 1.6.2 (/Users/raihan/Downloads/quitch-app/node_modules/#ionic/cli-plugin-cordova)
#ionic/cli-plugin-ionic-angular : 1.4.1 (/Users/raihan/Downloads/quitch-app/node_modules/#ionic/cli-plugin-ionic-angular)
#ionic/cli-utils : 1.6.0 (/Users/raihan/Downloads/quitch-app/node_modules/#ionic/cli-utils)
ionic (Ionic CLI) : 3.6.0 (/Users/raihan/Downloads/quitch-app/node_modules/ionic)
global packages:
Cordova CLI : 7.0.1
local packages:
#ionic/app-scripts : 2.0.2
Cordova Platforms : android 6.2.3 ios 4.5.1
Ionic Framework : ionic-angular 3.5.3
System:
Android SDK Tools : 26.0.2
Node : v6.11.3
OS : macOS High Sierra
Xcode : Xcode 9.0 Build version 9A235
ios-sim : 6.1.2
npm : 5.3.0
Any Help is highly appreciated.
I have fixed the errors. The issues are as follows -
The main problem was with the cordova-plugin-console plugin. Cordova do not support this plugin since cordova version-ios 4.5.0.
Also I had to provide the updated google-json file.
Now it is building successfully on XCode and Emulator.

opening an ionic App second time on iOS, app not working

I have developing hybrid ionic app, its working fine for android . In iOS , for first time when Open app its works perfect but after closing and re-open, app becomes hang. no any data load in app.
I have installed this plugins :
cordova-plugin-camera 2.4.0 "Camera"
cordova-plugin-compat 1.1.0 "Compat"
cordova-plugin-console 1.0.6 "Console"
cordova-plugin-device 1.1.5 "Device"
cordova-plugin-google-analytics 1.8.3 "Google Universal Analytics Plugin"
cordova-plugin-inappbrowser 1.7.0 "InAppBrowser"
cordova-plugin-network-information 1.3.2 "Network Information"
cordova-plugin-splashscreen 4.0.2 "Splashscreen"
cordova-plugin-statusbar 2.2.2 "StatusBar"
cordova-plugin-themeablebrowser 0.2.17 "ThemeableBrowser"
cordova-plugin-whitelist 1.3.3-dev "Whitelist"
cordova-plugin-x-socialsharing 5.1.7 "SocialSharing"
cordova-plugin-x-toast 2.6.0 "Toast"
ionic-plugin-keyboard 2.2.1 "Keyboard"
We had this exact issue!
It was to do with ionic auto updates. It would download some update on the first app run and apply it on the second app run.
We fixed it by removing the cordova-plugin-ionic plugin as we didn't actually want the functionality.
ionic cordova plugin remove cordova-plugin-ionic

module com.pushwoosh.plugins.pushwoosh.PushNotification not found

I recently rebuilt my iOS platform in my ionic/cordova project. In that process I somehow broke my push functionality. Before this it worked beautifully.
Now, when I launch the app to a device in Xcode:
In Xcode debugger I see all the normal pushwoosh API calls happening as the app is loading but without the APP ID, so they're all failing.
The important thing here is that the plugin is being loaded seems to be trying to work
Right after those errors in the console, I get this one, which I can only see when I attach a safari console debugger to the app running on the phone:
module com.pushwoosh.plugins.pushwoosh.PushNotification not found
The app just goes to a white screen, and I am pretty sure it's because of that error - when I test the app out in a browser (where cordova is not loaded), it runs fine.
I set my APP ID right from the start of the app with this:
var pushNotification = cordova.require("com.pushwoosh.plugins.pushwoosh.PushNotification");
pushNotification.onDeviceReady({
pw_appid: PW_APPID
});
I have uninstalled and reinstalled the plugin several times. I have removed and then added the platform as well. In this process I tried updating my cordova-ios to 4.1.0 but that introduced a whole new set of headaches, so I reverted back to cordova-ios 3.8.0
What other troubleshooting can I do to see what is going on?
Here's some other diagnostics....
RocketHQ:rr-app-newest laphona$ ionic -v
1.7.14
RocketHQ:rr-app-newest laphona$ cordova -v
6.0.0
RocketHQ:rr-app-newest laphona$ cordova plugin list
com.cordova.plugins.sms 0.1.9 "Cordova SMS Plugin"
com.unarin.cordova.beacon 3.4.0 "Proximity Beacon Plugin"
cordova-plugin-app-event 1.2.0 "Application Events"
cordova-plugin-bluetooth-serial 0.4.5 "Bluetooth Serial"
cordova-plugin-calendar 4.4.7 "Calendar"
cordova-plugin-camera 2.1.1 "Camera"
cordova-plugin-console 1.0.2 "Console"
cordova-plugin-device 1.1.1 "Device"
cordova-plugin-file 4.1.1 "File"
cordova-plugin-file-transfer 1.5.0 "File Transfer"
cordova-plugin-freshdesk-mobihelp 1.1.0 "Mobihelp Plugin for Phonegap"
cordova-plugin-geolocation 2.1.0 "Geolocation"
cordova-plugin-google-analytics 0.8.1 "Google Universal Analytics Plugin"
cordova-plugin-inappbrowser 1.3.0 "InAppBrowser"
cordova-plugin-network-information 1.2.0 "Network Information"
cordova-plugin-splashscreen 3.2.1 "Splashscreen"
cordova-plugin-whitelist 1.2.1 "Whitelist"
cordova-sqlite-storage 0.8.4-dev "Cordova sqlite storage plugin (core version)"
cordova.plugins.diagnostic 2.3.13 "Diagnostic"
de.appplant.cordova.plugin.local-notification 0.8.4 "LocalNotification"
ionic-plugin-keyboard 2.0.1 "Keyboard"
org.nypr.cordova.hockeyappplugin 0.1.0 "Device"
org.nypr.cordova.nslogger-cocoalumberjack-connector-plugin 0.1.0 "Device"
pushwoosh-cordova-plugin 4.2.2
I just found out from the cordova pushwoosh authors:
To support latest version of Cordova and Ionic we had to rename plugin
id to
var pushNotification =
cordova.require("pushwoosh-cordova-plugin.PushNotification");
It's reflected in the docs.

Resources