Cordoba loads an application into an android emulator

I am completely unfamiliar with Cordova, but now I installed Cordova with NPM and installed the Android SDK and configured AVD, which seems to work fine until I want to emulate my project. If the actual application for some reason does not load into the emulator.

The following action has been taken:

marvin:HelloWorld$ cordova -d emulate android cordova library for "android" already exists. No need to download. Continuing. Wrote out Android application name to "HelloWorld" Wrote out Android package name to "com.example.hello" Calling plugman.prepare for platform "android" Preparing android project... Processing configuration changes for plugins. Iterating over installed plugins: [] Writing out cordova_plugins.js... Running on emulator for platform "android" via command ""/home/marvin/Development/projects/HelloWorld/platforms/android/cordova/run" --emulator" (output to follow)... 

Then it launches the Android emulator, but the application is not there. Anyone have a suggestion to fix this problem so that I can actually test in my emulator?

Thanks in advance.

+4
source share
8 answers

I had the same problem and I lacked PATH for the platform tool in the sdk folder for Android after I added that everything was in place.

+8
source

I had the same problem; I could run the cordova emulate android command very well, and the emulator would eventually start up and function, however the test application was never installed on the device. I did not get any errors from the Cordova CLI or console or anything else.

I found that there is an error report here: https://issues.apache.org/jira/browse/CB-4285

Two solutions were found to solve this problem: 1. Make sure that you are using the Oracle JDK, not the IBM JDK, and 2. Make sure that the AVD that starts the emulation has min-target-sdk installed in API 10 (Android 2.3 .3) or higher. (That was my problem.)

+6
source

Sometimes it removes the previously installed version of the application in the emulator. To do this, you can also launch it using the "Clear user data" option.

For the record only, none of the other solutions worked for me.

+2
source

I had the same problem. After that I decided to do it.

Make sure the API level of your AVD is greater than minSdkVersion specified in the config.xml file specified in your cordova application.

+1
source

If anyone else has this problem:

I had the same problem with a disconnected device.

If ddms works, it looks at the connected devices.

 adb kill server 

and how to start ddms

0
source

Also, make sure your application identifier does not start with a number or any other character, such as "_". For example, if your application identifier is com.4company.MyApp or com._company.MyApp , it simply will not load into the emulator. The first of these is due to the fact that Java does not allow names starting with the number , and the second does not allow Cordoba revenue.

You should also use adb logcat to display emulator errors on the command line.

0
source

For me, the application did not start, because I had a second emulator running in the background. Removing bluestacks (Android emulator for Windows) fixed the problem in my case. Running "adb logcat" should tell you if you have multiple emulators.

0
source

I had the same problem and it was my emulator device that was with API 15. Just upgraded to API 17 and the problem was resolved.

0
source

Source: https://habr.com/ru/post/1493714/


All Articles