3

Today I wanted to test how Meteor's android build worked. So I installed Meteor and created a test to-do app per their instructions. Then pr. instructions from here I installed the Java SDK, and confirmed I had the Android SDK from when I installed Visual Studio 2015.

Then came my first problem. When I tried to run meteor add-platform android from the command prompt. I got the error Cannot find module ‘is-property’, and quickly learned to fix this by cd'ing to the directory missing the module and running npm install is-property. A hat tip to this thread for the solution.

Okay, one more time: meteor add-platform android and this time with success. I then ran meteor run android, and sure enough, an emulator launched with my app. Or almost. Because the first message that greeted me was Application Error - The connection to the server was unsuccessful (http://localhost:12784) and the app crashed.

After searching around a bit, it seemed that because the emulator was so damn slow, the meteor script timed out and caused the crash. So I then tried installing Android Studio to use Android AVD manager. But now the emulator wouldn't even launch, and I got stock with the following:

enter image description here

Starting app on android emulator and then... nothing.

So I tried to uninstall all android sdks, android studio, and meteor.

Then I tried to

  1. Installing meteor again.
  2. Install only the Android SDK command line tools.
  3. Added the Android SDK to my environment variables.
  4. Ran the android.bat to make sure I installed almost all the newest tools and images plus the Intel x86 Emulator Accelerator (HAXM installer) List item
  5. I Then tried running the meteor run android command again, only to get stuck at starting app on android emulator as seen in the first picture.
  6. Let the Starting app on android emulator run for an hour plus to see if things were just slow.

I have also tried to follow advice from the following resources without help:

And btw, here is how my AVD config looks like

enter image description here

So what have I done wrong? Everything would not be a surprising answer. Jokes aside, what is it I need to do to get a proper running android emulator up for my meteor app on windows 10?

Community
  • 1
  • 1
MartinJH
  • 2,590
  • 5
  • 36
  • 49

2 Answers2

2

I was getting exactly the same thing, but I finally figured out the problem.

I tried running the emulator from the command-line:

emulator -avd Android_Emulator

This actually gave me a useful error message:

emulator: ERROR: x86 emulation currently requires hardware acceleration!
Please ensure Intel HAXM is properly installed and usable.
CPU acceleration status: HAXM is not installed on this machine

This StackOverflow thread helped figure out how to install this: Intel X86 emulator accelerator (HAXM installer) VT/NX not enabled

And then it worked! Really really slow! But it worked.

Community
  • 1
  • 1
jeffrey_t_b
  • 1,779
  • 12
  • 18
  • this gave me an error about missing Qt library, which in result led me to missing emulator executable in PATH and this solution https://stackoverflow.com/a/44822312/266561 – Alex K Feb 26 '20 at 08:12
0

Try removing your Virtual Device and recreate it again, or try a different one. Next, rebuild your meteor app proyect.

Removing you virtual device

Android-Studio >> Configure >> AVD Manager >> Delete

In my case, no issues about Intel HXAM (already installed), but the virtual device was working time ago, suddenly, the "Starting app on android emulator" never ended. I think, its about cordova+npm related issues. So, try this.

In meteor proyect folder, try rebuild de app-cordova things using

  • Deleting .meteor/local/corova-build
  • Deleting .meteor/node_modules
  • Removing and adding android plaftorm with meteor remove-plarform android && meteor add-platform android
  • Running the commands meteor rebuild && meteor npm install
  • Ensure compatibility NodeJS libraries. In my case, meteor 1.8.2, nodejs 12.9.
EdU
  • 71
  • 4