You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@cordova.apache.org by "Reid Lai (JIRA)" <ji...@apache.org> on 2014/01/15 10:33:21 UTC

[jira] [Created] (CB-5798) unknown handled error event when emulating android

Reid Lai created CB-5798:
----------------------------

             Summary: unknown handled error event when emulating android 
                 Key: CB-5798
                 URL: https://issues.apache.org/jira/browse/CB-5798
             Project: Apache Cordova
          Issue Type: Bug
          Components: CLI
    Affects Versions: 3.3.0
         Environment: Windows 7, JDK 1.7.0 Update 21, Android SDK Tools 20.3, Android Platform Tools 19.0.1
            Reporter: Reid Lai


Dear Sir/Madam,

I try to create a blank new project using Cordova 3.3 and encounter unhandled error event when emulating android.  

Here are my steps
1. cordova create abc
2.cd abc
3. cordova platform add android
4. cordova build android
5. cordova emulate android => Unhandled 'error' event
6. emulator -avd Nexus4_442 => AVD works

Up to step 4, everything works fine.  Then I try step 5 to emulate my app running into AVD, I got the following error:

C:\GitLocal\HKRI\GenRx>cordova emulate android
Generating config.xml from defaults for platform "android"
Preparing android project
Running on emulator for platform "android" via command "cmd" /c C:\GitLocal\HKRI
\GenRx\platforms\android\cordova\run --emulator

C:\Users\reid.lai\AppData\Roaming\npm\node_modules\cordova\node_modules\q\q.js:1
26
                    throw e;
                          ^
Error: An error occurred while emulating/deploying the android project.
events.js:72
        throw er; // Unhandled 'error' event
              ^
Error: spawn ENOENT
    at errnoException (child_process.js:980:11)
    at Process.ChildProcess._handle.onexit (child_process.js:771:34)

    at ChildProcess.<anonymous> (C:\Users\reid.lai\AppData\Roaming\npm\node_modu
les\cordova\src\emulate.js:67:22)
    at ChildProcess.EventEmitter.emit (events.js:98:17)
    at maybeClose (child_process.js:735:16)
    at Socket.<anonymous> (child_process.js:948:11)
    at Socket.EventEmitter.emit (events.js:95:17)
    at Pipe.close (net.js:466:12)

I also tried step 6 to test AVD and SDK setting and AVD successfully starts.

In my PATH environment variables, I checked Platform Tools and Tools path of Android SDK.  Any hint to solve this problem?  Thanks.




--
This message was sent by Atlassian JIRA
(v6.1.5#6160)