0
votes

I'm getting a number of errors when running my Meteor app on Android via Cordova

=> Started your app. => App running at: http://localhost:3000/ (android:http://meteor.local/cordova.js:1169) deviceready has not fired after 5 seconds. (android:http://meteor.local/cordova.js:1162) Channel not fired: onDOMContentLoaded (android:http://meteor.local/client/templates/analytics/types/template.bagging_and_tagging_analytics.js:2) Uncaught ReferenceError: Template is not defined (android:http://meteor.local/client/templates/analytics/types/template.biological_notice_analytics.js:2) Uncaught ReferenceError: Template is not defined (android:http://meteor.local/client/templates/analytics/types/template.farmer_triage_analytics.js:2) Uncaught ReferenceError: Template is not defined (android:http://meteor.local/client/templates/analytics/types/template.fertilizer_application_analytics.js:2) Uncaught ReferenceError: Template is not defined (android:http://meteor.local/lib/collections/blocks.js:1) Uncaught ReferenceError: Mongo is not defined (android:http://meteor.local/lib/collections/forms.js:1) Uncaught ReferenceError: Mongo is not defined (android:http://meteor.local/lib/collections/ground_db_users.js:1) Uncaught ReferenceError: Meteor is not defined (android:http://meteor.local/lib/collections/notifications.js:1) Uncaught ReferenceError: Mongo is not defined (android:http://meteor.local/lib/helpers/get_connection_status.js:1) Uncaught ReferenceError: UI is not defined (android:http://meteor.local/client/startup/connection_tracker.js:1) Uncaught ReferenceError: Tracker is not defined (android:http://meteor.local/packages/multiply_iron-router-progress.js:52) Uncaught ReferenceError: Spacebars is not defined I20150522-00:30:55.484(3)? at Router.configure.waitOn (http://meteor.local/lib/router.js?a620a3574120a8292b544d367fc6fc742b854698:7:8) I20150522-00:30:55.484(3)? at http://meteor.local/packages/iron_router.js?a427868585af16bb88b7c9996b2449aebb8dbf51:1199:36 I20150522-00:30:55.484(3)? at _.extend.withValue (http://meteor.local/packages/meteor.js?4dc9757b244a30bdf37a732ac4db4026ce56fb6b:981:17) I20150522-00:30:55.485(3)? at hookWithOptions (http://meteor.local/packages/iron_router.js?a427868585af16bb88b7c9996b2449aebb8dbf51:1198:27) I20150522-00:30:55.485(3)? at http://meteor.local/packages/iron_router.js?a427868585af16bb88b7c9996b2449aebb8dbf51:438:22 I20150522-00:30:55.485(3)? at Array.forEach (native) I20150522-00:30:55.485(3)? at Function..each..forEach (http://meteor.local/packages/underscore.js?0a80a8623e1b40b5df5a05582f288ddd586eaa18:156:11) I20150522-00:30:55.485(3)? at RouteController._runRoute (http://meteor.local/packages/iron_router.js?a427868585af16bb88b7c9996b2449aebb8dbf51:437:5) I20150522-00:30:55.485(3)? at Function.Route.dispatch (http://meteor.local/packages/iron_router.js?a427868585af16bb88b7c9996b2449aebb8dbf51:844:18)

1
may i know your command to run on android device? - Ramesh Murugesan
are you using deviceready. Instead of deviceready, invoke your code in Meteor.startup or templates onRendered - Ramesh Murugesan
I'm not sure I understand "deviceready" instead of "deviceready" All my templates are using OnRendered and I don't have any functionality which relies on a Cordova/Phonegap plugin should wrap code in a Meteor.startup() block. - Almog Koren
if (Meteor.isClient) { Meteor.startup(function() { //cordova code }); } this is my code. It works fine in my app - Ramesh Murugesan

1 Answers

0
votes

All the errors were caused by the Meteor Message Format package. Once removed it compiled just fine.