How to solve the problem "com.google.android.gms.auth.api.signin.internal.SignInHubActivity" ActivityNotFoundException in google signin integration

I have a built-in google application in an Android application, but when I launch the application, I get an exception, for example:

android.content.ActivityNotFoundException: Cannot find explicit activity class {Com.example / com.google.android.gms.auth.api.signin.internal.SignInHubActivity};

Have you announced this activity in your AndroidManifest.xml?

Can you tell me how I declare SignInHubActivity in the AndroidManifest.xml file

+7
source share
3 answers

Indeed, I made a very stupid mistake. I just announce the type of activity below ...

<activity android:name="com.google.android.gms.auth.api.signin.internal.SignInHubActivity" android:screenOrientation="portrait" android:windowSoftInputMode="stateAlwaysHidden|adjustPan" /> 

Now my problem is solved. Google signin works fine .... Thanks

+11
source

Are you using Eclipse with ADT? (Plugin for Android Development Tools). Have you followed the instructions here to set up the Google Play Services SDK? https://developers.google.com/android/guides/setup

If you set it up correctly, I’m sure that the SignInHubActivity definition will automatically be merged into your manifest from the Google Play Services SDK, and you don’t need to explicitly declare it.

+1
source

I had the same problem. Finally I solved it. This is called "Manuel Migration to AndroidX." I followed the instructions in this video: https://www.youtube.com/watch?v=0FZ_eUIsLTg

and the problem is resolved.

The key factor is updating compileSdkVersion to the latest version. and it is recommended to update all versions in the build.gradle, app / build.gradle, pubspec.yaml files.

then Android Studio successfully manages the migration, and the ActivityNotFoundException problem is resolved.

And the last reminder for the Turkish guys. You should modify these keywords (in app / build.gradle) as follows:

testImplementation → testİmplementation

androidTestImplementation → androidTestİmplementation

0
source

All Articles