admin管理员组文章数量:1429094
I'm using PhoneGap 2.7.0 and am following the simple mand line build/install instructions here. I'm building for Android, on Windows. My debugging and testing is mostly done in Chrome using Ripple, but also using the Android emulator and installed on my Nexus 7.
First, I'll say what works. For a simple ondeviceready
javascript code of the kind shown here in the PhoneGap documentation everything works great in Chrome, in the emulator, and on the device. I use the mand-line method of building and installing the code on the device as listed here:
$ /path/to/my_new_cordova_project/cordova/build.bat
$ /path/to/my_new_cordova_project/cordova/run.bat
Great. Now, es the problem. When I write some more javascript and test it in Chrome, everything is the same as it was before (working correctly), but when I try to run the cordova/build.bat
script, it runs silently as usual (no errors or warnings), finishes much quicker, BUT fails to produce an .apk
file. Question: Is there a good way to find out where the build.bat script fails and why?
The Chrome console output for all cases (when the build works and when it doesn't) is as follows. I have to fire the "deviceready" event manually in the Ripple emulator. But that's just a problem with the emulator and is not an issue when deployed to the device.
Ripple :: Environment Warming Up (Tea. Earl Gray. Hot.) ripple.js:37
GET http://localhost/thrifty-bunch-v1/assets/www/config.xml 404 (Not Found) ripple.js:50
cordova :: Initialization Finished (Make it so.) ripple.js:37
deviceready has not fired after 5 seconds. cordova-2.7.0.js:6672
Channel not fired: onPluginsReady cordova-2.7.0.js:6665
Channel not fired: onCordovaReady cordova-2.7.0.js:6665
Channel not fired: onCordovaConnectionReady cordova-2.7.0.js:6665
deviceready has not fired after 5 seconds. cordova-2.7.0.js:6672
Channel not fired: onPluginsReady cordova-2.7.0.js:6665
Channel not fired: onCordovaReady cordova-2.7.0.js:6665
Channel not fired: onCordovaConnectionReady
I'm using PhoneGap 2.7.0 and am following the simple mand line build/install instructions here. I'm building for Android, on Windows. My debugging and testing is mostly done in Chrome using Ripple, but also using the Android emulator and installed on my Nexus 7.
First, I'll say what works. For a simple ondeviceready
javascript code of the kind shown here in the PhoneGap documentation everything works great in Chrome, in the emulator, and on the device. I use the mand-line method of building and installing the code on the device as listed here:
$ /path/to/my_new_cordova_project/cordova/build.bat
$ /path/to/my_new_cordova_project/cordova/run.bat
Great. Now, es the problem. When I write some more javascript and test it in Chrome, everything is the same as it was before (working correctly), but when I try to run the cordova/build.bat
script, it runs silently as usual (no errors or warnings), finishes much quicker, BUT fails to produce an .apk
file. Question: Is there a good way to find out where the build.bat script fails and why?
The Chrome console output for all cases (when the build works and when it doesn't) is as follows. I have to fire the "deviceready" event manually in the Ripple emulator. But that's just a problem with the emulator and is not an issue when deployed to the device.
Ripple :: Environment Warming Up (Tea. Earl Gray. Hot.) ripple.js:37
GET http://localhost/thrifty-bunch-v1/assets/www/config.xml 404 (Not Found) ripple.js:50
cordova :: Initialization Finished (Make it so.) ripple.js:37
deviceready has not fired after 5 seconds. cordova-2.7.0.js:6672
Channel not fired: onPluginsReady cordova-2.7.0.js:6665
Channel not fired: onCordovaReady cordova-2.7.0.js:6665
Channel not fired: onCordovaConnectionReady cordova-2.7.0.js:6665
deviceready has not fired after 5 seconds. cordova-2.7.0.js:6672
Channel not fired: onPluginsReady cordova-2.7.0.js:6665
Channel not fired: onCordovaReady cordova-2.7.0.js:6665
Channel not fired: onCordovaConnectionReady
Share
Improve this question
asked May 12, 2013 at 21:34
Alan TuringAlan Turing
12.6k16 gold badges78 silver badges117 bronze badges
3 Answers
Reset to default 1There is a known issue (CB-3029) with cordova release 2.7.0.
Workaround:
Why does Cordova 2.7.0 JS seemingly no longer work on remote pages?
I think the error lies within phonegap 2.7. I have the same issue, it works with 2.6 but gives the same issue with 2.7. I also get the extra error code here:
cordova :: Initialization Finished (Make it so.)
Uncaught SyntaxError: Unexpected token < cordova.js:6816
deviceready has not fired after 5 seconds.
create a file cordova_plugins.json
that contains {}
. then go to cordova-2.7.0.js
and ment this line require('cordova/channel').onNativeReady.fire();
then when development done, add it back
本文标签: javascriptCordovaPhoneGap Build Script Fails SilentlyStack Overflow
版权声明:本文标题:javascript - CordovaPhoneGap Build Script Fails Silently - Stack Overflow 内容由网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://www.betaflare.com/web/1745541139a2662500.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论