I currently just created an Ionic 4 application and when i test on my android 5.1 device nothing shows, i go to google to find out what the issue could be and it turns out ionic 4 has a problem working on android 5.1 and lower devices. Is there anyway to get it to run on at least android 5.1 ?
It appears that Ionic has a closed issue on Github for this that states that Android 5 is not entirely supported:
https://github.com/ionic-team/ionic/issues/15438
One of the Ionic team members states:
"We are aware of this issue and have been working to fix it for some time. The main issue here is that there seems to be a constant stream of things that need to either be polyfill or reworked in order to support older Android. And to add to this, the android emulator is not always the best test ground
As the older android emulators are not connected to google play, they do not receive updates to the browser, meaning that though a real android 5 device might have chrome 70, the emulator is stuck on chrome 37 (~1% of the global market), which is a drastically different environment.
While we are making fixes internally in both stencil and ionic/(core,angular), devs can enable Angular Polyfills to fix some older features.
For most cases though, people will not be seeing "older" webviews that devs are getting in the Android emulator. They will be getting new chrome (70+) and all the latest web features.
We will we continuing to address this issue and make sure things work as expected."
Related
In continuation with this question. I am asking this question.
I installed Android Studio. I installed Unity 3D. I followed tutorials of Java-Android Studio and Unity. Nothing worked well because of the reason that they need the latest version of ARCore and neither my mobile nor emulator is compatible with it. I am exhausted searching for alternatives.
I didn't find any tutorial or guidance related to developing Augmented Reality Android apps. Please suggest me a reference that works on Ubuntu system without the need of the physical mobile, but with an emulator, if possible.
Note: Please provide a reference that is relatively easy to test small app initially so that I can proceed forward. I am saying this because of the reason that I am working from almost 3 months but didn't run a small AR app either in the emulator or in my mobile (Redmi Note - 4).
You should check 8thWall. It runs on almost all phones and it has SLAM as well. You can not use it with emulator but it has an application called XR Remote in which you can test your code without building for Android or iOS. Minimum requirement for Android is Android Kitkat (4.4) or higher and for iOS Minimum iOS 7.0 or later is required.
As the owner of the question stated 8thWall can not be used with Linux. As an alternative [ARToolKit] can be used. It is an open source AR framework. For more details you can refer here and here
I'm trying to teach myself JavaScript by creating an little puzzle/game app with Cordova. I've got a basic prototype thing working, and have successfully got it to build on iPhone, and it runs perfectly.
I have 3 android phones to test with, 1 Marshmallow (BLU branded), 1 Lollipop, and 1 Kitkat... and the app works perfectly on those as well. I sent the app to 2 friends on the other side of the country to test, and it crashes on their Samsung Marshmallow phones ( a Galaxy 7, and a Galaxy Edge 7). It runs for a bit, and then just crashes without any user input.
So, I tried 2 separate crash analytics plugins, Fabric and Crittercism. I can verify that both of these are working, as I can force a crash in the app, and it shows up as a crash report.
But when my friends run the app with the crash analytics, whatever is going on that makes the app blowup, it isn't triggering any reports from Fabric or Crittercism. I've tried to get the android emulator running on my PC, but unfortunately it is an AMD processor, which is missing some necessary virtualization. I can't even get the super slow ARM version of the emulator to run on my PC, it just hangs forever.
I just recently installed cordova, and took all the defaults during setup. So from what I can tell, it should be targeting android API 23 (Marshmallow). But maybe there's some other kind of build issue that is messing things up?
So I'm kind of at a loss of how to debug this problem. Short of finding someone locally who can lend me a Samsung Marshmallow phone to debug with, I can't think of anything else that would work. Does anyone have any ideas?
The ARM emulator is indeed excruciatingly slow. I would suggest a third-party emulator. I use GenyMotion (which uses VirtualBox under the hood). You might have some luck with that. Alternatively, ManyMo is a cloud-based solution that might prove useful.
The system web view used by PhoneGap/Cordova will vary widely across Android devices, which means you can run into different issues across Android versions and device manufacturers. I suggest using the Crosswalk plugin to mitigate those problems. Do note that this will increase the size of your APK and footprint of the installed app on your device.
When the app crashes, does it actually crash to the launcher, or does the app reload itself (or just show a background color)? I wouldn't expect Crashlytics to handle JavaScript issues unless the JavaScript caused the app to crash out to the launcher.
I am building an Android app for my company, using Android Studio 1.5.1 . I've discovered that the app won't work on some Galaxy S5 phones.
These phones just show a white screen when the app runs.
This error happens on Galaxy S5 devices with Android version 5.1.1 But not on an Galaxy S5 Device running Android version 5.0
I'm focusing on the Android Version as a clue to solving this bug.
I can't actually get one of the devices so I've created several Virtual Devices. There are 6 Downloadable system images of Android 5.1.1 in Android Studio's Virtual Device Configuration wizard. I've installed all of them. none replicate this white screen error.
What else can I do to uncover this bug?
If it helps answer my question, my app relies heavily on server communication. The whole app is just one Webview with a few html & JS files.
The problem with emulators is that they are not reproducing actual device behaviour(especially, once many OEMs like Samsung tend to customise Android based on their needs), so I'm afraid the only options you have are:
Get Samsung Galaxy S5 with 5.1.1
Apart from obvious ideas "go to shop and buy", I can recommend you:
to take a look at Open Device Lab. It operates around the world and there's an arguably good chance to find the device you need there;
build a pool of alpha-beta users you can talk to and share new builds. Google Play has quite rich functionality in this area. Samsung S5 is quite common model, so it shouldn't be a problem to find people with it. If your product is "public", you can try to find beta-users on services like BetaBound or just among your social media network;
Use Analytics tools to collect more data from affected devices and act based on the information you get
There're dozens of different frameworks for accomplishing it. I can suggest Crittercism as a super powerful and comprehensive tool. In particular, I'd definitely log:
All handled exceptions
Add breadcrumbs (short string to capture app run-time information) to all Activity/Fragment lifecycle methods, to Application's methods (as white screen on start might mean some issues there), to all meaningful async tasks, etc.
If app gets into suspicion state - log it as a handled exception, so you can see the whole trail of breadcrumbs and track history of exceptions for the user. Unfortunately, you won't get trail of breadcrumbs, before something has been logged as an issue (crash or exception). There're frameworks, which log everything, like MixPanel, for example, but I honestly think that Crittercism suits much more here)
Crittercism will also catch & report all crashes happen in the app and
The Get Started Guide is here and it's pretty straightforward: http://docs.crittercism.com/android/android.html
Saying that, I'd suggest you to integrate some analytics anyway, as it'll help you in the future and to try to get affected phone in hands for test.
I guess the culprit is webview. Can you check the webview version on which the issue is reproducible.
To check the version you need to go to settings->Application Manager-> Downloaded Apps-> check "Android System Webview"version
We had a similar issue when the screen used to go blank and it used to happen only on particular version of webview. The issue was fixed by Google later.
The chromium webview layer is now updatable from Google Play.
For more details refer-http://developer.android.com/about/versions/lollipop.html#WebView
I assume you are building a hybrid app.
If the webview is the culprit, you could try crosswalk.
It adds Mb's to your app but it makes sure every device uses the same webview (latest chromium). Moreover rendering differences etc are also minimized.
if you are using cordova run: cordova plugin add cordova-plugin-crosswalk-webview and that's it.
If you implement this and the whitescreen problem is gone, you debugged it in a sherlock holmish deduction way...
The problem is not with emulator. It is with WebView in Android versions 5.1 onward.
Try
uninstalling the updates for "Android system webview" app (go to
settings and look for it under "downloaded") it works just fine!
Source - similar question
I have this Phonegap application I'm working. Unfortunately, I having problems pertaining to a particular feature at the moment. I tried deploying on any iOS device, the error is present. Though by default, we programmers, should solve this problem right away. But I was wondering how I could see console.logs("..."); on Android.
I've search for related answers regarding this. Most of the answers mostly suggests I should use WebInspector using jshybugger. That won't be a problem unless I will be building the project on a level below API L19 (Kitkat) and maybe as low as API L10 (Gingerbread).
Using the AVD emulator was also a suggestion, yet I can't find a way to boot the emulator properly on my computer. And as we all know, Android Emulator is a hell of a snail compared to iOS Simulator.
Unlike for iOS I could just use the Safari Device Inspector to view the console logs and resources. I was hoping for a similar feature without using jshybugger and can be supported by at most Android API L10?
console.log should appear on the adb, you can see it on eclipse or on android monitor (monitor comes with the android sdk)
Or you can use this online debugger, it creates a javascript script that you put in your index and then you can see your phone debugger there. You can do it locally too using weinre
I'm about ready to release 6 apps on the Google Play market, and a guy at work brought in a new phone that was running a version of android that the manifest file stated was supported and it didn't work as expected even though it did work on the emulator. This brought up the question of
Short of buying every device, how can we ensure that our apps will work on all devices that run the versions of android that the manifest file says it supports?
Is there a suggested way to do this? The combinations of different screen sizes, densities, and android versions can make development for android a real pain.
Edit:
The part that "didn't work as expected" was some of the javascript calls. Especially calls like window.width and window.height, the width was reported as the height and the height was reported as the width on 2.3.4, but not 2.1, or 3+. Another issue, also with 2.3.4 and javascript was the window.open(url, target) call would only call the shouldOverrideUrlLoading on my WebViewClient the first time for each target rather than every time. Again, it worked with 2.1 and 3+.
Currently, I test on devices running 2.3.4, 2.3.5, 4.0.3, and 4.0.4. I also test on emulators running 2.1, 2.2, 2.3.3, 3.0, 3.1, 3.2, and 4.1 with various screen sizes and densities. The javascript bugs are not present on the 2.3.3 or any of the other emulators, which is why I would rather test on devices, they give me a more accurate feel of what the user will run into
To start, here is a presentation that discusses how to potentially address the problem. This is obviously not easy, but here is another similar SO post.
I don't exactly what you exactly mean by "didn't work as expected" but this can help you quite a lot:
In my opinion, the best way to test your Android application is to install a Jenkins Continuous Integration Server, and use the Android Emulator plugin to execute the application on your application builds on emulators with various settings (screen density, OS version, etc.). The plugin can take automatically screenshots so you can see afterwards how your application looks on each configuration. Also, builds and testing can be trigerred daily, or each time you commit some code on your SCM (Git, SVN, you name it).
The configuration of the plugin is detailed on the official page: https://wiki.jenkins-ci.org/display/JENKINS/Android+Emulator+Plugin