Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Depth first search hangs #2

Open
kpmoran opened this issue Aug 26, 2014 · 14 comments
Open

Depth first search hangs #2

kpmoran opened this issue Aug 26, 2014 · 14 comments

Comments

@kpmoran
Copy link

kpmoran commented Aug 26, 2014

Depth first search hangs at the following step:

shell$ adb shell am startservice -n umd.troyd/.Ignite -e AUT <app and activity name>

I am on Mac OSX with the latest version of ruby, ruby gems, and nokogiri installed.

@tanzirul
Copy link
Owner

Let me know the android version and app name you are working on. Also if possible provide the logcat output.

@kpmoran
Copy link
Author

kpmoran commented Aug 26, 2014

Thank you for the reply and for your help.

I have tried to run the tool with a Nexus 7 tablet running Android version 4.4.2 and on an emulator running version 4.1.2. the app is Mininote Google Play url: https://play.google.com/store/apps/details?id=com.mobillion.app.mininote&hl=en

Unfortunately, I cannot collect the logcat output at the moment, but I will upload it this evening.

@shauvik
Copy link

shauvik commented Aug 28, 2014

I am running into this very same issue on android 2.3.3 while testing the a2dp.Vol app. https://f-droid.org/wiki/page/a2dp.Vol

In my logcat, I see this wierd error about missing instrumentation package. This is perhaps from some unclean past run when I was testing another app. I tried looking but couldn't find where this is coming from.

Partial logcat:
D/AndroidRuntime( 1310): Calling main entry com.android.commands.am.Am
I/ActivityManager( 849): Start proc umd.troyd for service umd.troyd/.Ignite: pid=1318 uid=10031 gids={3002, 3001, 1015}
D/AndroidRuntime( 1310): Shutting down VM
D/dalvikvm( 1310): GC_CONCURRENT freed 99K, 70% free 315K/1024K, external 0K/0K, paused 0ms+0ms
D/jdwp ( 1310): adbd disconnected
W/ActivityManager( 849): Unable to find instrumentation target package: com.amazon.mShop.android
I/ActivityManager( 849): No longer want com.android.settings (pid 1048): hidden #16

@legacy21 I would be interested in seeing your logcat too. Please share.

@shauvik
Copy link

shauvik commented Aug 28, 2014

BTW, I just updated this project to the latest version on git and now I see a different missing target package in logcat. @tanzirul is it due to the recently committed files / binaries?

Partial logcat:
D/dalvikvm( 1249): GC_CONCURRENT freed 99K, 70% free 315K/1024K, external 0K/0K, paused 0ms+0ms
D/jdwp ( 1249): adbd disconnected
W/ActivityManager( 849): Unable to find instrumentation target package: net.jimblackler.newswidget
I/ActivityManager( 849): No longer want com.android.settings (pid 967): hidden #16
W/ActivityManager( 849): Activity destroy timeout for HistoryRecord{b74d6488 com.android.launcher/com.android.launcher2.Launcher}
W/ActivityManager( 849): finishReceiver called but no pending broadcasts

@shauvik
Copy link

shauvik commented Aug 28, 2014

I figured out the problem!

This is what was happening.. In the troyd/libs, there is guava-12 jar file, which fails to compile with the latest dex tools. To fix this, I replaced it with guava-15 from my $ANDROID_HOME/tools/lib/ and it compiled after that and A3E ran!

So, all this while, the committed binary version of troyd.apk was being installed on the AVD!! This makes sense as net.jimblackler.newswidget is in the AndroidManifest.xml file for troyd.

To debug, I set the QUIET variable in troyd.rb and other files to empty string " " and this let me see all build errors.

Two things to debug/fix such issues in future.

  • Please avoid committing binaries (e.g., troyd.apk) to Github. Especially when you compile them again on runtime.
  • I highly recommend that rec.rb takes another option -verbose and removes QUIET variables, as in troyd.rb to allow users to see everything that's going on.

@kpmoran
Copy link
Author

kpmoran commented Aug 29, 2014

Excellent News! Thanks for looking into this, I'm glad you were able to solve it :)

@kpmoran
Copy link
Author

kpmoran commented Sep 7, 2014

Just wanted to confirm that @shauvik's fix did work for me as well.

@gmendezm
Copy link

I fixed with the @shauvik 's tip but still hangs,

@andrirad
Copy link

Hi,

Did you all manage to fix this problem? I also tried the fix but the script keeps hanging. Below is a preview of what I have in logcat

D/dalvikvm(12420): GC_CONCURRENT freed 302K, 33% free 640K/944K, paused 0ms+0ms, total 2ms
I/ActivityManager( 788): Start proc a3e.process for service umd.troyd/.Ignite: pid=12438 uid=10065 gids={50065, 3003, 1028, 1015}
I/dalvikvm(12438): Enabling JNI app bug workarounds for target SDK version 10...
I/ActivityManager( 788): Force stopping com.ninegriddiary_beta appid=10065 user=0: start instr

@gowtham1984
Copy link

I have similar issue and logcat says.

10-06 16:07:36.977 21954 21954 E AndroidRuntime: java.lang.RuntimeException: Unable to get provider com.google.firebase.provider.FirebaseInitProvider: java.lang.NullPointerException: Application context cannot be null.
10-06 16:07:36.977 21954 21954 E AndroidRuntime: at android.app.ActivityThread.installProvider(ActivityThread.java:5156)
10-06 16:07:36.977 21954 21954 E AndroidRuntime: at android.app.ActivityThread.installContentProviders(ActivityThread.java:4748)
10-06 16:07:36.977 21954 21954 E AndroidRuntime: at android.app.ActivityThread.handleBindApplication(ActivityThread.java:4688)
10-06 16:07:36.977 21954 21954 E AndroidRuntime: at android.app.ActivityThread.-wrap1(ActivityThread.java)
10-06 16:07:36.977 21954 21954 E AndroidRuntime: at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1405)
10-06 16:07:36.977 21954 21954 E AndroidRuntime: at android.os.Handler.dispatchMessage(Handler.java:102)
10-06 16:07:36.977 21954 21954 E AndroidRuntime: at android.os.Looper.loop(Looper.java:148)
10-06 16:07:36.977 21954 21954 E AndroidRuntime: at android.app.ActivityThread.main(ActivityThread.java:5417)
10-06 16:07:36.977 21954 21954 E AndroidRuntime: at java.lang.reflect.Method.invoke(Native Method)
10-06 16:07:36.977 21954 21954 E AndroidRuntime: at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:726)
10-06 16:07:36.977 21954 21954 E AndroidRuntime: at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:616)
10-06 16:07:36.977 21954 21954 E AndroidRuntime: Caused by: java.lang.NullPointerException: Application context cannot be null.
10-06 16:07:36.977 21954 21954 E AndroidRuntime: at com.google.android.gms.common.internal.zzab.zzb(Unknown Source)
10-06 16:07:36.977 21954 21954 E AndroidRuntime: at com.google.firebase.FirebaseApp.initializeApp(Unknown Source)
10-06 16:07:36.977 21954 21954 E AndroidRuntime: at com.google.firebase.FirebaseApp.initializeApp(Unknown Source)
10-06 16:07:36.977 21954 21954 E AndroidRuntime: at com.google.firebase.FirebaseApp.zzek(Unknown Source)
10-06 16:07:36.977 21954 21954 E AndroidRuntime: at com.google.firebase.provider.FirebaseInitProvider.onCreate(Unknown Source)
10-06 16:07:36.977 21954 21954 E AndroidRuntime: at android.content.ContentProvider.attachInfo(ContentProvider.java:1748)
10-06 16:07:36.977 21954 21954 E AndroidRuntime: at android.content.ContentProvider.attachInfo(ContentProvider.java:1723)
10-06 16:07:36.977 21954 21954 E AndroidRuntime: at com.google.firebase.provider.FirebaseInitProvider.attachInfo(Unknown Source)
10-06 16:07:36.977 21954 21954 E AndroidRuntime: at android.app.ActivityThread.installProvider(ActivityThread.java:5153)
10-06 16:07:36.977 21954 21954 E AndroidRuntime: ... 10 more

After search, looks like Google Play version needed to be added in the AndroidManifest.xml which I tried putting it troyd/AndroidManifest.xml file by adding the following entry

and also create integers.xml defining google_play_services_version.

But, still the same error, can you please help me.

@tanzirul
Copy link
Owner

tanzirul commented Oct 6, 2016

Hi, can you first check whether you can install and uninstall the app through adb command?

Tanzirul Azim

On Oct 6, 2016, at 4:07 AM, Gowtham Rupavatharam <[email protected] mailto:[email protected]> wrote:

I have similar issue and logcat says.

10-06 16:07:36.977 21954 21954 E AndroidRuntime: java.lang.RuntimeException: Unable to get provider com.google.firebase.provider.FirebaseInitProvider: java.lang.NullPointerException: Application context cannot be null.
10-06 16:07:36.977 21954 21954 E AndroidRuntime: at android.app.ActivityThread.installProvider(ActivityThread.java:5156)
10-06 16:07:36.977 21954 21954 E AndroidRuntime: at android.app.ActivityThread.installContentProviders(ActivityThread.java:4748)
10-06 16:07:36.977 21954 21954 E AndroidRuntime: at android.app.ActivityThread.handleBindApplication(ActivityThread.java:4688)
10-06 16:07:36.977 21954 21954 E AndroidRuntime: at android.app.ActivityThread.-wrap1(ActivityThread.java)
10-06 16:07:36.977 21954 21954 E AndroidRuntime: at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1405)
10-06 16:07:36.977 21954 21954 E AndroidRuntime: at android.os.Handler.dispatchMessage(Handler.java:102)
10-06 16:07:36.977 21954 21954 E AndroidRuntime: at android.os.Looper.loop(Looper.java:148)
10-06 16:07:36.977 21954 21954 E AndroidRuntime: at android.app.ActivityThread.main(ActivityThread.java:5417)
10-06 16:07:36.977 21954 21954 E AndroidRuntime: at java.lang.reflect.Method.invoke(Native Method)
10-06 16:07:36.977 21954 21954 E AndroidRuntime: at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:726)
10-06 16:07:36.977 21954 21954 E AndroidRuntime: at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:616)
10-06 16:07:36.977 21954 21954 E AndroidRuntime: Caused by: java.lang.NullPointerException: Application context cannot be null.
10-06 16:07:36.977 21954 21954 E AndroidRuntime: at com.google.android.gms.common.internal.zzab.zzb(Unknown Source)
10-06 16:07:36.977 21954 21954 E AndroidRuntime: at com.google.firebase.FirebaseApp.initializeApp(Unknown Source)
10-06 16:07:36.977 21954 21954 E AndroidRuntime: at com.google.firebase.FirebaseApp.initializeApp(Unknown Source)
10-06 16:07:36.977 21954 21954 E AndroidRuntime: at com.google.firebase.FirebaseApp.zzek(Unknown Source)
10-06 16:07:36.977 21954 21954 E AndroidRuntime: at com.google.firebase.provider.FirebaseInitProvider.onCreate(Unknown Source)
10-06 16:07:36.977 21954 21954 E AndroidRuntime: at android.content.ContentProvider.attachInfo(ContentProvider.java:1748)
10-06 16:07:36.977 21954 21954 E AndroidRuntime: at android.content.ContentProvider.attachInfo(ContentProvider.java:1723)
10-06 16:07:36.977 21954 21954 E AndroidRuntime: at com.google.firebase.provider.FirebaseInitProvider.attachInfo(Unknown Source)
10-06 16:07:36.977 21954 21954 E AndroidRuntime: at android.app.ActivityThread.installProvider(ActivityThread.java:5153)
10-06 16:07:36.977 21954 21954 E AndroidRuntime: ... 10 more

After search, looks like Google Play version needed to be added in the AndroidManifest.xml which I tried putting it troyd/AndroidManifest.xml file by adding the following entry

and also create integers.xml defining google_play_services_version.

But, still the same error, can you please help me.


You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub #2 (comment), or mute the thread https://github.com/notifications/unsubscribe-auth/AFT6V2CdsqZPTBp2fa7uVdOxdUQlwIOAks5qxNZ-gaJpZM4CbPih.

@gowtham1984
Copy link

gowtham1984 commented Oct 7, 2016

Yes, was able to install & uninstall an app using adb command. Can you tell me what needs to be done to get it working. Thanks

@gowtham1984
Copy link

gowtham1984 commented Oct 7, 2016

and I see an error message on the mobile/emulator saying Unfortunately the process a3e.process has stopped with the above exception in adb logcat

@gowtham1984
Copy link

@tanzirul any help please ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants