Android Question Solved - App mysteriously stopped working

tsteward

Well-Known Member
Licensed User
Longtime User
So I come home today and load up B4A on my PC. Load my app, change 1 line of code and hit compile.
B4A complains androidx.annotations:annotations-experimental (Google Maven) is missing. So I install it.
Now I recompile in debug mode. It compiles, it installs and blinks on my phone screen and disappears.
IDE shows no lines of anything in the log.

Not sure what to do.
I have tried loading backup from 3 days ago and same thing
 

f0raster0

Well-Known Member
Licensed User
Longtime User
Sorry for the question :) ahah

1) Do you have:
#BridgeLogger: True when running in release mode?

2) Try to change the package name then try to install the app.

3) Just reinstall b4a, follow the steps (don't update the sdk)
 
Upvote 0

tsteward

Well-Known Member
Licensed User
Longtime User
Sorry for the question :) ahah

1) Do you have:
#BridgeLogger: True when running in release mode?

2) Try to change the package name then try to install the app.

3) Just reinstall b4a, follow the steps (don't update the sdk)
Yes I have #Bridgelogger : True
And I was thinking about re-installing but have not done that yet. Mainly because other apps will compile and work fine,
 
Upvote 0

MikeSW17

Active Member
Licensed User
it has server passwords and everything in it
You could perhaps privately ?) share a copy of your app APK with all 'confidential' information deleted/altered.
As the fault *seems* to be in the very early initialization stages, it shouldn't affect an, hopefully, eliminatory test on some other set-ups.
 
Upvote 0

tsteward

Well-Known Member
Licensed User
Longtime User
Day 3 still can't get app working. I have deleted everything and reinstalled B4A & sdk as per the instructions on this website.
Result is exactly the same 😭😭
 
Upvote 0

josejad

Expert
Licensed User
Longtime User
I've tested your app in firebase test lab, this is the error I get, maybe you can get some clues.

Try:

B4X:
java.lang.NoClassDefFoundError: Failed resolution of: Landroidx/arch/core/executor/ArchTaskExecutor;
     FATAL EXCEPTION: main
Process: lishi.assistand.tony.stewardgmail.com, PID: 14227
java.lang.NoClassDefFoundError: Failed resolution of: Landroidx/arch/core/executor/ArchTaskExecutor;
    at androidx.lifecycle.LifecycleRegistry.enforceMainThreadIfNeeded(LifecycleRegistry.java:316)
    at androidx.lifecycle.LifecycleRegistry.addObserver(LifecycleRegistry.java:172)
    at androidx.activity.ComponentActivity.<init>(ComponentActivity.java:228)
    at androidx.fragment.app.FragmentActivity.<init>(FragmentActivity.java:103)
    at androidx.appcompat.app.AppCompatActivity.<init>(AppCompatActivity.java:87)
    at lishi.assistand.tony.stewardgmail.com.main.<init>(main.java:17)
    at java.lang.Class.newInstance(Native Method)
    at android.app.AppComponentFactory.instantiateActivity(AppComponentFactory.java:69)
    at android.app.Instrumentation.newActivity(Instrumentation.java:1215)
    at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2869)
    at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:3086)
    at android.app.servertransaction.LaunchActivityItem.execute(LaunchActivityItem.java:78)
    at android.app.servertransaction.TransactionExecutor.executeCallbacks(TransactionExecutor.java:108)
    at android.app.servertransaction.TransactionExecutor.execute(TransactionExecutor.java:68)
    at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1816)
    at android.os.Handler.dispatchMessage(Handler.java:106)
    at android.os.Looper.loop(Looper.java:193)
    at android.app.ActivityThread.main(ActivityThread.java:6718)
    at java.lang.reflect.Method.invoke(Native Method)
    at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:493)
    at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:858)
Caused by: java.lang.ClassNotFoundException: Didn't find class "androidx.arch.core.executor.ArchTaskExecutor" on path: DexPathList[[zip file "/data/app/lishi.assistand.tony.stewardgmail.com-FkCDRHUeRhhy5me1jcekTA==/base.apk"],nativeLibraryDirectories=[/data/app/lishi.assistand.tony.stewardgmail.com-FkCDRHUeRhhy5me1jcekTA==/lib/arm64, /system/lib64]]
    at dalvik.system.BaseDexClassLoader.findClass(BaseDexClassLoader.java:134)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:379)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:312)
    ... 21 more
 
Upvote 0

tsteward

Well-Known Member
Licensed User
Longtime User
Ok I am getting somewhere after re-install
Off to work for the day but now am getting this error so probs just need to reinstall a bit more
Device locale: en
Found 106 strings.
Using FileProvider? true
** Service (starter) Start **
** Activity (main) Create, isFirst = true **
java.lang.NoClassDefFoundError: Failed resolution of: Landroid/support/v4/view/ViewConfigurationCompat;
at com.jeremyfeinstein.slidingmenu.lib.CustomViewAbove.initCustomViewAbove(CustomViewAbove.java:167)
at com.jeremyfeinstein.slidingmenu.lib.CustomViewAbove.<init>(CustomViewAbove.java:157)
at com.jeremyfeinstein.slidingmenu.lib.CustomViewAbove.<init>(CustomViewAbove.java:152)
at com.jeremyfeinstein.slidingmenu.lib.SlidingMenu.<init>(SlidingMenu.java:209)
at com.jeremyfeinstein.slidingmenu.lib.SlidingMenu.<init>(SlidingMenu.java:192)
at com.jeremyfeinstein.slidingmenu.lib.SlidingMenu.<init>(SlidingMenu.java:181)
at anywheresoftware.b4a.objects.SlidingMenuWrapper.Initialize(SlidingMenuWrapper.java:25)
at lishi.assistand.tony.stewardgmail.com.main._activity_create(main.java:888)
at java.lang.reflect.Method.invoke(Native Method)
at anywheresoftware.b4a.shell.Shell.runMethod(Shell.java:732)
at anywheresoftware.b4a.shell.Shell.raiseEventImpl(Shell.java:351)
at anywheresoftware.b4a.shell.Shell.raiseEvent(Shell.java:255)
at java.lang.reflect.Method.invoke(Native Method)
at anywheresoftware.b4a.ShellBA.raiseEvent2(ShellBA.java:144)
at lishi.assistand.tony.stewardgmail.com.main.afterFirstLayout(main.java:105)
at lishi.assistand.tony.stewardgmail.com.main.access$000(main.java:17)
at lishi.assistand.tony.stewardgmail.com.main$WaitForLayout.run(main.java:83)
at android.os.Handler.handleCallback(Handler.java:938)
at android.os.Handler.dispatchMessage(Handler.java:99)
at android.os.Looper.loop(Looper.java:246)
at android.app.ActivityThread.main(ActivityThread.java:8462)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:596)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1130)
Caused by: java.lang.ClassNotFoundException: android.support.v4.view.ViewConfigurationCompat
... 24 more
** Activity (main) Resume **
 
Upvote 0

Erel

B4X founder
Staff member
Licensed User
Longtime User
"Failed resolution of: Landroid/support/v4/view/ViewConfigurationCompat; "

This error means that you are using a library that depends on Android Support Library instead of AndroidX. This is the deprecated sliding menu library. You need to jetify the library. Make sure that the library resides in the additional libraries folder.
 
Upvote 0

tsteward

Well-Known Member
Licensed User
Longtime User
FIXED :):):)
So lesson learnt never update sdk Although I managed to compile successfully once it was what caused my problems.
Then after reinstalling I got the error with sliding menu library that I never had before. Not sure why but don't care. I have ditched it and swapped in B4X drawer.

All is good in the work and the sun will come up tomorrow.

Thank you all for your help.
 
Upvote 0
Top