We’ve had an app on the Google Play Store for a while now but recently some users are reporting that the app won’t open without an Internet connection. There is nothing in the app that requires an Internet connection so I don’t know where to track this bug down. Does not happen on iOS devices, only on the Android.
The error is they are reporting is “Connection to the server was unsuccessful file://android_asset/www/index.html”.
Any suggestions as to where I can locate this Internet request?
Thanks
EDIT:
Nearest I can tell by looking at the main html file for the app is a remote script call in the header tag to fontawesome.com: <script src="https://use.fontawesome.com/530b34dcfd.js"></script>
I’m assuming this may be the problem but is there way to load this source file locally so it’s not written in the header tag as a remote source?
The Chrome Remote Debugger sees the HTC ONE M8 fine when the actual Chrome browser is opened on the device. But when I run the app (compiled with Phonegap Build), the debugger changes to “No browsers detected.” Have never gotten the Remote debugger working with an AppStudio app using Phonegap Build.
What I do see when running the app via AppStudio’s “Start in Desktop Browser” when clicking the Sources tab is “use.fontawesome.com” with a cloud icon.
The error only seems to be happening on Android devices with no Internet connection when launching the app.
If you want a Debug Build, you need to clear the key to the right of the Android icon at the bottom and change it to “No key selected”. (On the PhoneGap Build site)
Ok, I generated a Debug Build and ran the Remote Debugger. All looked fine except for the initial “Could not find cordova.js script tag. Plugin loading may fail.” message.
Next, I closed the app, turned on Airplane Mode so there is no Internet connection, then started the app again, Boom… "Could not find cordova.js script tag. Plugin loading may fail." Failed to load resource: net::ERR_INTERNET_DISCONNECTED use.fontawesome.com/530b34dcfd.js:1
Looks like the remote request for fontawesome is the culprit?
If I port the app to AppStudio 7, is there a way to migrate the Bootstrap 3 controls to Bootstrap 4 without replacing every identical control? The app uses several buttons, inputs, grids and columns, and Media controls.
Per your AppStudio 7 notes, I don’t want to mix the two Bootstrap versions.
I cleared all instances of the “Icon” property but still saw the call for "<script src="https://use.fontawesome.com/530b34dcfd.js"></script> in the head tag after launching the app. It turns out that the Bootstrap Slider control needs (or at least calls for) fontawesome. Once that control is removed, the ’use.fontawesome...' script is removed from the head tag.
Also read that using font-awesome actually adds 1.5 to 2 seconds to the load time.
Just need to find an alternative to the slider control.