Search code examples
angularangular6nativescriptangular2-nativescriptnativescript-angular

nativescript errorPubNub call failed, check status for details


I set NativeScriptwithn angular 6 and every dependency is properly installed but got the below error with these steps

1) tns run --bundle

2) after that select option Sync to Playground

3) scan the QR code in playground app in my android mobile

4) show status: Successfully sent initial files for platform Android.

after that can see this error

Error: PubNub call failed, check the status for details at new PubNubError (/usr/local/lib/node_modules/nativescript/node_modules/pubnub/lib/core/components/core/components/endpoint.js:8:31) at onResponse (/usr/local/lib/node_modules/nativescript/node_modules/pubnub/lib/core/components/core/components/endpoint.js:126:32) at <anonymous> (/usr/local/lib/node_modules/nativescript/node_modules/pubnub/lib/networking/modules/networking/modules/web-node.js:59:17) at Request.callback (/usr/local/lib/node_modules/nativescript/node_modules/superagent/lib/node/index.js:728:3) at RequestBase._timeoutError (/usr/local/lib/node_modules/nativescript/node_modules/superagent/lib/request-base.js:676:8) at Timeout.<anonymous> (/usr/local/lib/node_modules/nativescript/node_modules/superagent/lib/request-base.js:685:12) at ontimeout (timers.js:475:11) at tryOnTimeout (timers.js:310:5) at Timer.listOnTimeout (timers.js:270:5)

Also I can see some warning after the run project with command tns run --bundle

1)The ANDROID_HOME environment variable is not set or it points to a non-existent directory. You will not be able to perform any build-related operations for Android.

2) WARNING: adb from the Android SDK is not installed or is not configured properly.

3)WARNING: The Android SDK is not installed or is not configured properly.

4) Cannot find a compatible Android SDK for compilation. To be able to build for Android, install Android SDK 28 or later. Run $ sdkmanager to manage your Android SDK versions.

5) You need to have the Android SDK Build-tools installed on your system. You can install any version in the following range: '>=23 <=28'.


Solution

  • I solved my issue this issue is set the environment on Ubuntu systems I provide the link and follow all instruction and command https://evothings.com/doc/build/cordova-install-linux.html I hope everyone uses this link and solved your problem