hopfenspace / Unciv

Open-source Android/Desktop remake of Civ V

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Android: currently unknown instant app crash

CrsiX opened this issue · comments

commented

I have no logs or other information (empty logcat), but the app crashes instantly on my Android.

Confirmed broken versions

Working versions

Conclusion

Something changed here which now breaks the Android app:
ef3152e..8d4d7dc

Debugging

Indeed, after some debugging, I now have a stack trace:

Error during onResume/disableReconnecting of com.unciv.app.AndroidLauncher@e74ad49: kotlin.UninitializedPropertyAccessException: lateinit property onlineMultiplayer has not been initialized
Message: lateinit property onlineMultiplayer has not been initialized
kotlin.UninitializedPropertyAccessException: lateinit property onlineMultiplayer has not been initialized
	at com.unciv.UncivGame.getOnlineMultiplayer(UncivGame.kt:132)
	at com.unciv.app.AndroidLauncher.onResume(AndroidLauncher.kt:103)
	at android.app.Instrumentation.callActivityOnResume(Instrumentation.java:1564)
	at android.app.Activity.performResume(Activity.java:8473)
	at android.app.ActivityThread.performResumeActivity(ActivityThread.java:4760)
	at android.app.ActivityThread.handleResumeActivity(ActivityThread.java:4803)
	at android.app.servertransaction.ResumeActivityItem.execute(ResumeActivityItem.java:57)
	at android.app.servertransaction.ActivityTransactionItem.execute(ActivityTransactionItem.java:45)
	at android.app.servertransaction.TransactionExecutor.executeLifecycleState(TransactionExecutor.java:179)
	at android.app.servertransaction.TransactionExecutor.execute(TransactionExecutor.java:97)
	at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2303)
	at android.os.Handler.dispatchMessage(Handler.java:106)
	at android.os.Looper.loopOnce(Looper.java:201)
	at android.os.Looper.loop(Looper.java:288)
	at android.app.ActivityThread.main(ActivityThread.java:7884)
	at java.lang.reflect.Method.invoke(Native Method)
	at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:548)
	at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:936)

This means, I need a check on initialization of that property first.

commented

This has been addressed and should be solved.