Open karina-y opened 4 years ago
I have the same problem with Meteor 2.3.2. The files reported as missing are all cordova plugin files and are in fact in the .meteor/local/cordova_build/platforms/android/platform_www/plugins folder.
In the APK file, these files are stored in assets\www\plugins, not in assets\www\application
I20210721-23:48:08.744(-4)? 07-21 23:48:01.006 19586 24232 W MeteorWebApp: Asset /__cordova/app/global-imports.js found in bundle 071c2567c164213bd6cce1d16a2b54ceabd0d28c:file:///android_asset/www/application
I20210721-23:48:08.744(-4)? 07-21 23:48:01.007 19586 24201 W MeteorWebApp: Asset /__cordova/app/app.js found in bundle 071c2567c164213bd6cce1d16a2b54ceabd0d28c:file:///android_asset/www/application
I20210721-23:48:08.774(-4)? 07-21 23:48:02.672 19586 24201 W MeteorWebApp: Asset /cordova_plugins.js not found in bundle 071c2567c164213bd6cce1d16a2b54ceabd0d28c:file:///android_asset/www/application, no parent bundle
I20210721-23:48:08.786(-4)? 07-21 23:48:05.089 19586 24212 W MeteorWebApp: Asset /plugins/cordova-plugin-geolocation/www/android/geolocation.js not found in bundle 071c2567c164213bd6cce1d16a2b54ceabd0d28c:file:///android_asset/www/application, no parent bundle
I20210721-23:48:08.786(-4)? 07-21 23:48:05.114 19586 24199 W MeteorWebApp: Asset /plugins/cordova-plugin-geolocation/www/PositionError.js not found in bundle 071c2567c164213bd6cce1d16a2b54ceabd0d28c:file:///android_asset/www/application, no parent bundle
I20210721-23:48:08.787(-4)? 07-21 23:48:05.120 19586 24201 W MeteorWebApp: Asset /plugins/cordova-plugin-splashscreen/www/splashscreen.js not found in bundle 071c2567c164213bd6cce1d16a2b54ceabd0d28c:file:///android_asset/www/application, no parent bundle
I20210721-23:48:08.787(-4)? 07-21 23:48:05.121 19586 24264 W MeteorWebApp: Asset /plugins/cordova-plugin-statusbar/www/statusbar.js not found in bundle 071c2567c164213bd6cce1d16a2b54ceabd0d28c:file:///android_asset/www/application, no parent bundle
I20210721-23:48:08.787(-4)? 07-21 23:48:05.121 19586 24212 W MeteorWebApp: Asset /plugins/cordova-plugin-device/www/device.js not found in bundle 071c2567c164213bd6cce1d16a2b54ceabd0d28c:file:///android_asset/www/application, no parent bundle
I20210721-23:48:08.787(-4)? 07-21 23:48:05.122 19586 24264 W MeteorWebApp: Asset /plugins/cordova.plugins.diagnostic/www/android/diagnostic.location.js not found in bundle 071c2567c164213bd6cce1d16a2b54ceabd0d28c:file:///android_asset/www/application, no parent bundle
I20210721-23:48:08.787(-4)? 07-21 23:48:05.123 19586 24212 W MeteorWebApp: Asset /plugins/cordova.plugins.diagnostic/www/android/diagnostic.camera.js not found in bundle 071c2567c164213bd6cce1d16a2b54ceabd0d28c:file:///android_asset/www/application, no parent bundle
I20210721-23:48:08.788(-4)? 07-21 23:48:05.123 19586 24232 W MeteorWebApp: Asset /plugins/cordova-plugin-meteor-webapp/www/webapp_local_server.js not found in bundle 071c2567c164213bd6cce1d16a2b54ceabd0d28c:file:///android_asset/www/application, no parent bundle
I20210721-23:48:08.788(-4)? 07-21 23:48:05.124 19586 24201 W MeteorWebApp: Asset /plugins/cordova.plugins.diagnostic/www/android/diagnostic.js not found in bundle 071c2567c164213bd6cce1d16a2b54ceabd0d28c:file:///android_asset/www/application, no parent bundle
I20210721-23:48:08.788(-4)? 07-21 23:48:05.126 19586 24212 W MeteorWebApp: Asset /plugins/cordova.plugins.diagnostic/www/android/diagnostic.external_storage.js not found in bundle 071c2567c164213bd6cce1d16a2b54ceabd0d28c:file:///android_asset/www/application, no parent bundle
I20210721-23:48:08.788(-4)? 07-21 23:48:05.127 19586 24264 W MeteorWebApp: Asset /plugins/cordova.plugins.diagnostic/www/android/diagnostic.notifications.js not found in bundle 071c2567c164213bd6cce1d16a2b54ceabd0d28c:file:///android_asset/www/application, no parent bundle
I20210721-23:48:08.788(-4)? 07-21 23:48:05.127 19586 24229 W MeteorWebApp: Asset /plugins/phonegap-plugin-push/www/push.js not found in bundle 071c2567c164213bd6cce1d16a2b54ceabd0d28c:file:///android_asset/www/application, no parent bundle
I20210721-23:48:08.788(-4)? 07-21 23:48:05.252 19586 24305 I MeteorWebApp: Startup completed received. New good version is 071c2567c164213bd6cce1d16a2b54ceabd0d28c
I20210721-23:48:08.789(-4)? 07-21 23:48:05.279 19586 24232 W MeteorWebApp: Asset /favicon.ico found in bundle 071c2567c164213bd6cce1d16a2b54ceabd0d28c:file:///android_asset/www/application
I20210721-23:48:57.357(-4)? 07-21 23:48:56.924 22838 22838 E chromium: [ERROR:aw_browser_terminator.cc(123)] Renderer process (22951) crash detected (code -1).
W20210721-23:52:17.345(-4)? (STDERR) Debugger did not attach after 5 minutes; continuing.
=> Started your app.
I did not have this problem with 2.2.1 or earlier versions of Meteor.
Hello @karina-y. You are using android-device with a local mobile-server URL, this won't work:
--mobile-server=http://localhost:3000
You have to use a network IP, that has to be accessible from your emulator/device. ex: http://192.168.15.1:3000
@cpravetz can you provide a reproduction? Or double-check if it's not the same issue as karina.
We are definitely using the right mobile-server in our build. I'll try to create a small reproduction.
Okay, running this set of commands:
meteor create cordtest
cd cordtest
meteor add-platform android
meteor add cordova:cordova-plugin-androidx-adapter@1.1.3
meteor run android-device --mobile-server=http://192.168.7.247:3000
Gives the same result as I had before. Ran it with two different cordova plugins to eliminate that as the problem.
hi @cpravetz sorry, I've missed your message. Can you try to add this snippet to your mobile-config and see if it solves your issue?
App.appendToConfig(`
<edit-config file="app/src/main/AndroidManifest.xml" mode="merge" target="/manifest/application" xmlns:android="http://schemas.android.com/apk/res/android">
<application android:usesCleartextTraffic="true"></application>
</edit-config>
`);
Facing the same problem on Meteor 2.3.5, appending the recommended config does not solve the issue.
Hi @pouya-eghbali. Can you provide a reproduction, please? I can't repro following @cpravetz steps. My output is as following:
➜ cordtest meteor run android-device --mobile-server=http://192.168.248.164:3000
[[[[[ ~/Projects/cordtest ]]]]]
=> Started proxy.
=> Started HMR server.
=> Started MongoDB.
cordova-plugin-androidx-adapter: Processed 17 source files in 230ms==] 100% 0.0s
WARNING: You are testing your app on a remote device. For the mobile app to be
able to connect to the local server, make sure your device is on the
same network, and that the network configuration allows clients to
talk to each other (no client isolation).
cordova-plugin-androidx-adapter: Processed 17 source files in 194ms
Checking Java JDK and Android SDK versions
ANDROID_SDK_ROOT=/home/renanccastro/Android/Sdk (recommended setting)
ANDROID_HOME=/home/renanccastro/Android/Sdk (DEPRECATED)
Using Android SDK: /home/renanccastro/Android/Sdk
=> Started your app.
=> App running at: http://localhost:3000/
Starting a Gradle Daemon (subsequent builds will be faster)
BUILD SUCCESSFUL in 2s
1 actionable task: 1 executedvice -
Starting a Gradle Daemon (subsequent builds will be faster)
> Task :app:compileDebugJavaWithJavac
Note: Some input files use or override a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
Note: Some input files use unchecked or unsafe operations.
Note: Recompile with -Xlint:unchecked for details.
Deprecated Gradle features were used in this build, making it incompatible with Gradle 7.0.
Use '--warning-mode all' to show the individual deprecation warnings.
See https://docs.gradle.org/6.5/userguide/command_line_interface.html#sec:command_line_warnings
BUILD SUCCESSFUL in 8s
41 actionable tasks: 41 executede -
Checking Java JDK and Android SDK versions
ANDROID_SDK_ROOT=/home/renanccastro/Android/Sdk (recommended setting)
ANDROID_HOME=/home/renanccastro/Android/Sdk (DEPRECATED)
Using Android SDK: /home/renanccastro/Android/Sdk
%% No target specified and no devices found, deploying to emulator
=> Started app on Android Device.
And the app works as usual.
Is this impacting you in any way, or is it only debug messages happening in the adb log?
I still get the messages in 2.3.5 as well. My app was slow to start in earlier 2.3.x versions and I believed the cordova file finding might be related, but the app would eventually run properly. With 2.3.5, the debug messages remain, but the delay in start up has not, and the app opens quickly and runs correctly.
error i'm getting a 'not found' on cordova assets
when i check meteor.status it says i'm not connected and i'm wondering if this is the issue. i'm currently down a rabbit hole of trying to figure out why running my app locally on android won't connect to my local db and through days of googling i've ended up here. please let me know if there's any other info needed to help me get through this bug.
env meteor: 1.10.2 os: ubuntu 18.0.4
repro
i've tried running with both these scripts:
i've tried manually adding the assets via meteor add but nothing changed.
logs for
meteor run android-device --mobile-server=http://localhost:3000
logs for
MONGO_URL=mongodb://un:pw@localhost:27017/dbName meteor run android-device --mobile-server=http://localhost:3000