3rob3/ImmichFrame

Crashes on Fire HD 8 Plus tablet

midiwidi opened this issue · 29 comments

Version

1.0.1.0

Deployment Method

Android Tablet (Fire HD 8 Plus)

Description

When the app is started, it shows a white background and closes immediately.

Reproduction

  • Install the signed APK version
  • Launch the app

Expectations

The app starts and shows the configuration screen.
(It runs fine on my Samsung phone)

Configuration

No response

Logs

...
05-05 00:40:02.988  3988 31269 D AppsManager: Upfront app: com.immichframe.immichframe
05-05 00:40:03.321  8252  8252 D AndroidRuntime: Shutting down VM
--------- beginning of crash
05-05 00:40:03.322  8252  8252 E AndroidRuntime: FATAL EXCEPTION: main
05-05 00:40:03.322  8252  8252 E AndroidRuntime: Process: com.immichframe.immichframe, PID: 8252
05-05 00:40:03.322  8252  8252 E AndroidRuntime: android.runtime.JavaProxyThrowable: System.ArgumentOutOfRangeException: Arg_ArgumentOutOfRangeException
05-05 00:40:03.322  8252  8252 E AndroidRuntime:    at Avalonia.Android.Platform.AndroidPlatformSettings.OnViewConfigurationChanged(Context )
05-05 00:40:03.322  8252  8252 E AndroidRuntime:    at Avalonia.Android.AvaloniaView.OnConfigurationChanged()
05-05 00:40:03.322  8252  8252 E AndroidRuntime:    at Avalonia.Android.AvaloniaView..ctor(Context )
05-05 00:40:03.322  8252  8252 E AndroidRuntime:    at Avalonia.Android.AvaloniaMainActivity`1[[ImmichFrame.App, ImmichFrame, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null]].InitializeApp()
05-05 00:40:03.322  8252  8252 E AndroidRuntime:    at Avalonia.Android.AvaloniaMainActivity`1[[ImmichFrame.App, ImmichFrame, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null]].OnCreate(Bundle )
05-05 00:40:03.322  8252  8252 E AndroidRuntime:    at Android.App.Activity.n_OnCreate_Landroid_os_Bundle_(IntPtr , IntPtr , IntPtr )
05-05 00:40:03.322  8252  8252 E AndroidRuntime:    at Android.Runtime.JNINativeWrapper.Wrap_JniMarshal_PPL_V(_JniMarshal_PPL_V , IntPtr , IntPtr , IntPtr )
05-05 00:40:03.322  8252  8252 E AndroidRuntime: 	at crc6431345fe65afe8d98.AvaloniaMainActivity_1.n_onCreate(Native Method)
05-05 00:40:03.322  8252  8252 E AndroidRuntime: 	at crc6431345fe65afe8d98.AvaloniaMainActivity_1.onCreate(AvaloniaMainActivity_1.java:41)
05-05 00:40:03.322  8252  8252 E AndroidRuntime: 	at android.app.Activity.performCreate(Activity.java:7151)
05-05 00:40:03.322  8252  8252 E AndroidRuntime: 	at android.app.Activity.performCreate(Activity.java:7141)
05-05 00:40:03.322  8252  8252 E AndroidRuntime: 	at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1271)
05-05 00:40:03.322  8252  8252 E AndroidRuntime: 	at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2908)
05-05 00:40:03.322  8252  8252 E AndroidRuntime: 	at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:3069)
05-05 00:40:03.322  8252  8252 E AndroidRuntime: 	at android.app.servertransaction.LaunchActivityItem.execute(LaunchActivityItem.java:78)
05-05 00:40:03.322  8252  8252 E AndroidRuntime: 	at android.app.servertransaction.TransactionExecutor.executeCallbacks(TransactionExecutor.java:108)
05-05 00:40:03.322  8252  8252 E AndroidRuntime: 	at android.app.servertransaction.TransactionExecutor.execute(TransactionExecutor.java:68)
05-05 00:40:03.322  8252  8252 E AndroidRuntime: 	at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1818)
05-05 00:40:03.322  8252  8252 E AndroidRuntime: 	at android.os.Handler.dispatchMessage(Handler.java:106)
05-05 00:40:03.322  8252  8252 E AndroidRuntime: 	at android.os.Looper.loop(Looper.java:193)
05-05 00:40:03.322  8252  8252 E AndroidRuntime: 	at android.app.ActivityThread.main(ActivityThread.java:6734)
05-05 00:40:03.322  8252  8252 E AndroidRuntime: 	at java.lang.reflect.Method.invoke(Native Method)
05-05 00:40:03.322  8252  8252 E AndroidRuntime: 	at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:493)
05-05 00:40:03.322  8252  8252 E AndroidRuntime: 	at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:858)
05-05 00:40:03.324  8252  8252 W monodroid-assembly: Shared library 'liblog' not loaded, p/invoke '__android_log_print' may fail
05-05 00:40:03.336  8252  8252 I MonoDroid: UNHANDLED EXCEPTION:
05-05 00:40:03.341  8252  8252 I MonoDroid: Android.Runtime.JavaProxyThrowable: Exception_WasThrown, Android.Runtime.JavaProxyThrowable
05-05 00:40:03.342  8252  8252 I MonoDroid: 
05-05 00:40:03.342  8252  8252 I MonoDroid:   --- End of managed Android.Runtime.JavaProxyThrowable stack trace ---
05-05 00:40:03.342  8252  8252 I MonoDroid: android.runtime.JavaProxyThrowable: System.ArgumentOutOfRangeException: Arg_ArgumentOutOfRangeException
05-05 00:40:03.342  8252  8252 I MonoDroid:    at Avalonia.Android.Platform.AndroidPlatformSettings.OnViewConfigurationChanged(Context )
05-05 00:40:03.342  8252  8252 I MonoDroid:    at Avalonia.Android.AvaloniaView.OnConfigurationChanged()
05-05 00:40:03.342  8252  8252 I MonoDroid:    at Avalonia.Android.AvaloniaView..ctor(Context )
05-05 00:40:03.342  8252  8252 I MonoDroid:    at Avalonia.Android.AvaloniaMainActivity`1[[ImmichFrame.App, ImmichFrame, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null]].InitializeApp()
05-05 00:40:03.342  8252  8252 I MonoDroid:    at Avalonia.Android.AvaloniaMainActivity`1[[ImmichFrame.App, ImmichFrame, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null]].OnCreate(Bundle )
05-05 00:40:03.342  8252  8252 I MonoDroid:    at Android.App.Activity.n_OnCreate_Landroid_os_Bundle_(IntPtr , IntPtr , IntPtr )
05-05 00:40:03.342  8252  8252 I MonoDroid:    at Android.Runtime.JNINativeWrapper.Wrap_JniMarshal_PPL_V(_JniMarshal_PPL_V , IntPtr , IntPtr , IntPtr )
05-05 00:40:03.342  8252  8252 I MonoDroid: 	at crc6431345fe65afe8d98.AvaloniaMainActivity_1.n_onCreate(Native Method)
05-05 00:40:03.342  8252  8252 I MonoDroid: 	at crc6431345fe65afe8d98.AvaloniaMainActivity_1.onCreate(AvaloniaMainActivity_1.java:41)
05-05 00:40:03.342  8252  8252 I MonoDroid: 	at android.app.Activity.performCreate(Activity.java:7151)
05-05 00:40:03.342  8252  8252 I MonoDroid: 	at android.app.Activity.performCreate(Activity.java:7141)
05-05 00:40:03.342  8252  8252 I MonoDroid: 	at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1271)
05-05 00:40:03.342  8252  8252 I MonoDroid: 	at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2908)
05-05 00:40:03.342  8252  8252 I MonoDroid: 	at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:3069)
05-05 00:40:03.342  8252  8252 I MonoDroid: 	at android.app.servertransaction.LaunchActivityItem.execute(LaunchActivityItem.java:78)
05-05 00:40:03.342  8252  8252 I MonoDroid: 	at android.app.servertransaction.TransactionExecutor.executeCallbacks(TransactionExecutor.java:108)
05-05 00:40:03.342  8252  8252 I MonoDroid: 	at android.app.servertransaction.TransactionExecutor.execute(TransactionExecutor.java:68)
05-05 00:40:03.342  8252  8252 I MonoDroid: 	at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1818)
05-05 00:40:03.342  8252  8252 I MonoDroid: 	at android.os.Handler.dispatchMessage(Handler.java:106)
05-05 00:40:03.342  8252  8252 I MonoDroid: 	at android.os.Looper.loop(Looper.java:193)
05-05 00:40:03.342  8252  8252 I MonoDroid: 	at android.app.ActivityThread.main(ActivityThread.java:6734)
05-05 00:40:03.342  8252  8252 I MonoDroid: 	at java.lang.reflect.Method.invoke(Native Method)
05-05 00:40:03.342  8252  8252 I MonoDroid: 	at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:493)
05-05 00:40:03.342  8252  8252 I MonoDroid: 	at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:858)
05-05 00:40:03.342  8252  8252 I MonoDroid: 
05-05 00:40:03.342  8252  8252 I MonoDroid:   --- End of managed Android.Runtime.JavaProxyThrowable stack trace ---
05-05 00:40:03.342  8252  8252 I MonoDroid: android.runtime.JavaProxyThrowable: System.ArgumentOutOfRangeException: Arg_ArgumentOutOfRangeException
05-05 00:40:03.342  8252  8252 I MonoDroid:    at Avalonia.Android.Platform.AndroidPlatformSettings.OnViewConfigurationChanged(Context )
05-05 00:40:03.342  8252  8252 I MonoDroid:    at Avalonia.Android.AvaloniaView.OnConfigurationChanged()
05-05 00:40:03.342  8252  8252 I MonoDroid:    at Avalonia.Android.AvaloniaView..ctor(Context )
05-05 00:40:03.342  8252  8252 I MonoDroid:    at Avalonia.Android.AvaloniaMainActivity`1[[ImmichFrame.App, ImmichFrame, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null]].InitializeApp()
05-05 00:40:03.342  8252  8252 I MonoDroid:    at Avalonia.Android.AvaloniaMainActivity`1[[ImmichFrame.App, ImmichFrame, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null]].OnCreate(Bundle )
05-05 00:40:03.342  8252  8252 I MonoDroid:    at Android.App.Activity.n_OnCreate_Landroid_os_Bundle_(IntPtr , IntPtr , IntPtr )
05-05 00:40:03.342  8252  8252 I MonoDroid:    at Android.Runtime.JNINativeWrapper.Wrap_JniMarshal_PPL_V(_JniMarshal_PPL_V , IntPtr , IntPtr , IntPtr )
05-05 00:40:03.342  8252  8252 I MonoDroid: 	at crc6431345fe65afe8d98.AvaloniaMainActivity_1.n_onCreate(Native Method)
05-05 00:40:03.342  8252  8252 I MonoDroid: 	at crc6431345fe65afe8d98.AvaloniaMainActivity_1.onCreate(AvaloniaMainActivity_1.java:41)
05-05 00:40:03.342  8252  8252 I MonoDroid: 	at android.app.Activity.performCreate(Activity.java:7151)
05-05 00:40:03.342  8252  8252 I MonoDroid: 	at android.app.Activity.performCreate(Activity.java:7141)
05-05 00:40:03.342  8252  8252 I MonoDroid: 	at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1271)
05-05 00:40:03.342  8252  8252 I MonoDroid: 	at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2908)
05-05 00:40:03.342  8252  8252 I MonoDroid: 	at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:3069)
05-05 00:40:03.342  8252  8252 I MonoDroid: 	at android.app.servertransaction.LaunchActivityItem.execute(LaunchActivityItem.java:78)
05-05 00:40:03.342  8252  8252 I MonoDroid: 	at android.app.servertransaction.TransactionExecutor.executeCallbacks(TransactionExecutor.java:108)
05-05 00:40:03.342  8252  8252 I MonoDroid: 	at android.app.servertransaction.TransactionExecutor.execute(TransactionExecutor.java:68)
05-05 00:40:03.342  8252  8252 I MonoDroid: 	at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1818)
05-05 00:40:03.342  8252  8252 I MonoDroid: 	at android.os.Handler.dispatchMessage(Handler.java:106)
05-05 00:40:03.342  8252  8252 I MonoDroid: 	at android.os.Looper.loop(Looper.java:193)
05-05 00:40:03.342  8252  8252 I MonoDroid: 	at android.app.ActivityThread.main(ActivityThread.java:6734)
05-05 00:40:03.342  8252  8252 I MonoDroid: 	at java.lang.reflect.Method.invoke(Native Method)
05-05 00:40:03.342  8252  8252 I MonoDroid: 	at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:493)
05-05 00:40:03.343  8252  8252 I MonoDroid: 	at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:858)
05-05 00:40:03.343  8252  8252 I MonoDroid: 
05-05 00:40:03.359   568   893 W ActivityManager:   Force finishing activity com.immichframe.immichframe/crc64ae3d3485feafd6e3.MainActivity
05-05 00:40:03.367  8252  8252 I Process : Sending signal. PID: 8252 SIG: 9
05-05 00:40:03.370   568  8284 I CrashReporterActivityManagerCallback: addErrorToDropBox inserted hashcode=14c6d91750763cb14e20f806c49432744d24d5d2 for eventType crash.
...

Pre-Submission Checklist

  • This is a bug report and not a feature request

  • I have provided all of the required information to reproduce the bug (config, logs, etc.)

  • I have checked for related issues and checked the documentation

Thanks for the logs. Hard to say for sure, but seems to be crashing trying to load the Settings screen/view. This is going to be tough to track down, let me see if I can create a virtual Fire HD device.

Anyone else tried this on a Fire HD tablet?

Not sure if that is related but I thought I add a note here. Is ImmichFrame using WebView?
I had problems with the immich website only showing a white page in the Fully Kiosk Browser. I was able to solve this by updating WebView from "Amazon System WebView 75.amazon-webview-v75-3770-tablet.3770.143.214" to "Amazon System WebView 110.amazon-webview-v110-5481-tablet.5481.154.24".
Unfortunately this didn't make a difference for ImmichFrame. It still crashes. Maybe it needs an even newer version or the vanilla Android one. My phone runs Android WebView version 123.0.6312.121 and there ImmichFrame works.

Not sure if that is related but I thought I add a note here. Is ImmichFrame using WebView? I had problems with the immich website only showing a white page in the Fully Kiosk Browser. I was able to solve this by updating WebView from "Amazon System WebView 75.amazon-webview-v75-3770-tablet.3770.143.214" to "Amazon System WebView 110.amazon-webview-v110-5481-tablet.5481.154.24". Unfortunately this didn't make a difference for ImmichFrame. It still crashes. Maybe it needs an even newer version or the vanilla Android one. My phone runs Android WebView version 123.0.6312.121 and there ImmichFrame works.

Thank you for your comment. ImmichFrame is not using WebView. It only shows images downloaded via the immich API.

I guess Amazon doesn't support creating Fire device emulators anymore. Hopefully someone else chimes in who has a Fire tablet.

Ok. Let me know if you want me to run any tests which would help you to figure out the problem.

Ok. Let me know if you want me to run any tests which would help you to figure out the problem.

Would you mind giving this APK a try? It is the same version # as the last release so you may need to uninstall/reinstall:
https://github.com/3rob3/ImmichFrame/releases/download/v1.0.1.0/com.immichframe.immichframe-Signed-BETA.zip

I uninstalled ImmichFrame and installed the version from the zip file you posted above.
When I ran it it crashed immediately just like last time. I can extract the logs with the crash if you want.
Did you expect something different to happen running the same version?

Haha. New build, I just didn't increment the version number. Only change was I removed our splash screen. Android build shows it's own splash screen automatically so thought maybe the issue was there. Do you see the immich logo/splash at all, or does it just go white right away? What version of Android does that tablet run?

No I don't see any logo or splash screen. When I click on the icon I get just a white screen which then closes in <1s.
Here is the version information I was able to extract

[ro.build.configuration]: [tablet]
[ro.build.date]: [Mon Aug  3 01:17:28 UTC 2020]
[ro.build.description]: [onyx-user 7.0 PS7315 1958 amz-p,release-keys]
[ro.build.display.id]: [PS7315]
[ro.build.fingerprint]: [Amazon/onyx/onyx:7.0/PS7315/1958N:user/amz-p,release-keys]
[ro.build.product]: [onyx]
[ro.build.version.all_codenames]: [REL]
[ro.build.version.base_os]: [PPR1.180610.009]
[ro.build.version.codename]: [REL]
[ro.build.version.fireos]: [7.0]
[ro.build.version.incremental]: [0018354775684]
[ro.build.version.min_supported_target_sdk]: [17]
[ro.build.version.name]: [Fire OS 7.3.1.5 (PS7315/1958)]
[ro.build.version.number]: [0018354775684]
[ro.build.version.preview_sdk]: [0]
[ro.build.version.release]: [9]
[ro.build.version.sdk]: [28]
[ro.build.version.security_patch]: [2018-10-05]

Fire OS 7 is based on Android 9 (Pie) API level 28. Could you test if it crashes there using Android Studio?

It works fine, that’s one of my testing emulators. Also works fine on Android 5.0 with upcoming release. I wish someone else could try on another Fire device, or I knew someone who had one.

I have a second fire tablet. Also a HD 8 but the non Plus version. I'll test it on there tonight.

Oh good, thanks. Let me know.

I ran ImmichFrame on my second Fire HD tablet and the same as on my other tablet happened. After starting the app I get a white screen and then I'm back in the app launcher (Crash).
Could we narrow down where in your code the crash happens by adding debug log information to to the code which is written to a text file? I could run the app and send you the file then,

This is odd, we just had another user (on Discord) report that it is working on their HD 8 tablet.

Hey, there is a new release out. I don't expect it to fix your issue, but it includes a new error screen which allows you to copy exception details. Hopefully it gets there before crashing :).

Thanks for pointing that out. I tested the new version but unfortunately it crashes before the error screen comes up. If the screen contains different information than the system log which could help to solve the problem, maybe you can make a special version which writes the information out to a file.

22ca67ea-7d64-46ab-8702-44625c2b85ac1715899657713.mp4

Your using the Signed APK right?

Yes, that's correct. From memory the other one wouldn't event install.

Yeah, we should really remove that.

Thanks for pointing that out. I tested the new version but unfortunately it crashes before the error screen comes up. If the screen contains different information than the system log which could help to solve the problem, maybe you can make a special version which writes the information out to a file.

22ca67ea-7d64-46ab-8702-44625c2b85ac1715899657713.mp4

Its not even showing the splash screen, the only thing done before that is telling Android to display fullscreen. This makes sense with your log you posted above. I can try commenting that out and making a build for you. I think we might be calling this too soon and the view is not loaded yet

Try this and let me know what happens (I put it under the previous release just to avoid others downloading it:
https://github.com/3rob3/ImmichFrame/releases/download/v1.0.1.0/com.immichframe.immichframe-Signed_TEST_1.apk
If this works for you I can create another build, and move setting fullscreen down further to give the intial view more time to load.

Thanks for the test version. I uninstalled my current version and installed the test version. It doesn't behave any different. The screen turns white and after 5 to 6 seconds it closes.

Bummer, really thought that might be it. There is really nothing else that happens before the splash screen (which we already tried disabling), so there really isn't any additional logging we can do. My only guess is some kind of permissions issue. What doesn't make sense is you are the only person to have reported this.

Damn. I was hoping we can figure out at which code line or happens.
Could the problem be related to me using the Fire HD Toolbox
https://xdaforums.com/t/windows-linux-tool-fire-toolbox-v34-0.3889604/ to replace the default app launcher, add Google apps like the play store and do some other adjustments? But on the other hand ImmichFrame is the only app I have problems with.
Btw. on my phone I don't see a splash screen. The first view shown is the configuration screen. It also takes less than a second until it's coming up whereas on my tablet I get that white screen for more 5 seconds.

I guess it depends on the device. My Pixel emulator shows the immich icon as a splash screen while loading the app. If settings are not valid the first thing you will see is Settings page. Otherwise you should see our splash screen (immich logo) then quickly transition to first photo.

My only physical Android device is a very old OnePlus 2 phone, it also shows a blank white screen for ~5 seconds before splash and photo. So I am guessing this is due to processor speed.

Regarding Fire HD Toolbox, I have no idea why it would, but would make sense why it is working for others. I was going to suggest factory resetting then trying again. I know that's a total PITA but not really sure what else to try.

I don't want to do a factory reset on my tablets and go through the hassle of setting everything up from scratch just to see if ImmichFrame would work in the stock configuration which I don't want to use anyway. I will stick to the web based slide show of Immich for now and insert some information such as date and time using JavaScript in the Fully Kiosk Browser.

Maybe it is some incompatibility with the Avalonia framework. I tried to find other apps which use Avalonia to see if they run OK on my tablet but it seems they are quite rare. There were only 2 mentioned on the Avalonia Showcase website one of which is not available in the Google Play Store in my country and the other one Avalonia Solitaire doesn't come as an APK and I would have to compile it myself. I don't want to setup a dev environment just for that. If you know any let me know. Btw, you should get your app on the showcase site to add to the ones supporting Android.

It's not an Avalonia issue, as mentioned others are running it on Fire HD tablets successfully. I understand you not wanting to run stock Fire OS or even try (since you would never run that way anyway), but at this point it seems something to do with your configuration. So unless/until we get more reports of similar I think this issue needs to be closed.