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

App has stoped #135

Open
TheOneMonkey opened this issue Oct 21, 2017 · 7 comments
Open

App has stoped #135

TheOneMonkey opened this issue Oct 21, 2017 · 7 comments

Comments

@TheOneMonkey
Copy link

FATAL EXCEPTION: main
Process: com.surya.pictactoe, PID: 10035
android.content.ActivityNotFoundException: No Activity found to handle Intent { act=android.intent.action.VIEW dat=https://play.google.com/... pkg=com.android.vending }
at android.app.Instrumentation.checkStartActivityResult(Instrumentation.java:1936)
at android.app.Instrumentation.execStartActivity(Instrumentation.java:1615)
at android.app.Activity.startActivityForResult(Activity.java:4472)
at android.support.v4.app.BaseFragmentActivityApi16.startActivityForResult(BaseFragmentActivityApi16.java:54)
at android.support.v4.app.FragmentActivity.startActivityForResult(FragmentActivity.java:65)
at android.app.Activity.startActivityForResult(Activity.java:4430)
at android.support.v4.app.FragmentActivity.startActivityForResult(FragmentActivity.java:711)
at android.app.Activity.startActivity(Activity.java:4791)
at android.app.Activity.startActivity(Activity.java:4759)
at hotchemi.android.rate.DialogManager$1.onClick(DialogManager.java:39)
at com.android.internal.app.AlertController$ButtonHandler.handleMessage(AlertController.java:166)
at android.os.Handler.dispatchMessage(Handler.java:105)
at android.os.Looper.loop(Looper.java:164)
at android.app.ActivityThread.main(ActivityThread.java:6541)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.Zygote$MethodAndArgsCaller.run(Zygote.java:240)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:767)

screenshot_1508569211

@carlos-ferreira
Copy link

You're testing on a image that doesn't have google play, that's why it's crashing.

@soheilshz
Copy link

FATAL EXCEPTION: main
Process: com.surya.pictactoe, PID: 10035
android.content.ActivityNotFoundException: No Activity found to handle Intent { act=android.intent.action.VIEW dat=https://play.google.com/... pkg=com.android.vending }
at android.app.Instrumentation.checkStartActivityResult(Instrumentation.java:1936)
at android.app.Instrumentation.execStartActivity(Instrumentation.java:1615)
at android.app.Activity.startActivityForResult(Activity.java:4472)
at android.support.v4.app.BaseFragmentActivityApi16.startActivityForResult(BaseFragmentActivityApi16.java:54)
at android.support.v4.app.FragmentActivity.startActivityForResult(FragmentActivity.java:65)
at android.app.Activity.startActivityForResult(Activity.java:4430)
at android.support.v4.app.FragmentActivity.startActivityForResult(FragmentActivity.java:711)
at android.app.Activity.startActivity(Activity.java:4791)
at android.app.Activity.startActivity(Activity.java:4759)
at hotchemi.android.rate.DialogManager$1.onClick(DialogManager.java:39)
at com.android.internal.app.AlertController$ButtonHandler.handleMessage(AlertController.java:166)
at android.os.Handler.dispatchMessage(Handler.java:105)
at android.os.Looper.loop(Looper.java:164)
at android.app.ActivityThread.main(ActivityThread.java:6541)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.Zygote$MethodAndArgsCaller.run(Zygote.java:240)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:767)

@TheOneMonkey
Copy link
Author

TheOneMonkey commented Nov 30, 2017 via email

@hendrawd
Copy link

Related to #53

@AlexanderLS
Copy link

@TheOneMonkey @carlos-ferreira @soheilshz @hendrawd Fix it on Vorlonsoft/AndroidRate. Works fine on the current release 1.1.7.

@trotterellone
Copy link

Hello, You don't handle in the case of the play store isn't installed?

@AlexanderLS
Copy link

AlexanderLS commented Oct 17, 2018

Hi @trotterellone

https://github.com/Vorlonsoft/AndroidRate handles the case if the user hasn't the Google Play on the device - the library starts intent to the web URI https://play.google.com/store/apps/details?id={your.app.package} (new Intent(Intent.ACTION_VIEW, Uri.parse("https://play.google.com/store/apps/details?id={your.app.package}")))

Also you can set other store than the Google Play - .setStoreType(StoreType)

Also you can use:

  if (AppRate.with(this).getStoreType() == StoreType.GOOGLEPLAY) { // Checks that current app store type from library options is StoreType.GOOGLEPLAY
      if (GoogleApiAvailability.getInstance().isGooglePlayServicesAvailable(this) != ConnectionResult.SERVICE_MISSING) { // Checks that Google Play is available
          AppRate.showRateDialogIfMeetsConditions(this); // Shows the Rate Dialog when conditions are met
      } else {
          // Do something
      }
  } else { 
      AppRate.showRateDialogIfMeetsConditions(this);     // Shows the Rate Dialog when conditions are met
  }

Latest stable version

dependencies {
    implementation "com.vorlonsoft:androidrate:1.2.1"
}

Latest snapshot version

repositories {
    maven { url "https://oss.sonatype.org/content/repositories/snapshots/" }
}
dependencies {
    implementation "com.vorlonsoft:androidrate:1.2.5-SNAPSHOT"
}

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