Description
On devices running Android 14, calling
GoogleSignIn.instance.authenticate() (the google_sign_in v7 API)
never shows the account picker. A transparent HiddenActivity from
androidx.credentials.playservices.controllers.identityauth is
launched and stays alive, which causes the status bar to go dark, but
no bottom sheet or dialog appears. Pressing the system back button
dismisses the HiddenActivity
The user never saw any UI — they did not cancel anything.
Steps to Reproduce
- Create a new Flutter app with
sdk: ^3.12.0 and google_sign_in: ^7.2.0 and Firebase.
- Call
GoogleSignIn.instance.initialize() then
GoogleSignIn.instance.authenticate() on button press.
- Run on an Android 14, API 34.
- Tap the sign-in button.
Expected Behavior
The Credential Manager dialog appears and lets the user pick a
Google account.
Actual Behavior
- Status bar darkens briefly (transparent
HiddenActivity is shown).
- No account picker or bottom sheet renders.
- After pressing back,
GoogleSignInExceptionCode.canceled is thrown.
Relevant Log Output
D/ActivityThread: ++ activityComponent: com.example.app/androidx.credentials.playservices.controllers.identityauth.HiddenActivity
D/TranActivityAppturboImpl: onResumeHork
D/VRI[HiddenActivity]: hardware acceleration = true
E/OpenGLRenderer: Unable to match the desired swap behavior.
I/flutter: Error occurred while signing in: GoogleSignInException(code GoogleSignInExceptionCode.canceled, activity is cancelled by the user., null)
D/BLASTBufferQueue: [VRI[HiddenActivity]#2] destructor()
W/PlayServicesImpl( 5416): Connection with Google Play Services was not successful. Connection result is: ConnectionResult{statusCode=SERVICE_VERSION_UPDATE_REQUIRED, resolution=null, message=null, clientMethodKey=null}
E/flutter ( 5416): [ERROR:flutter/runtime/dart_vm_initializer.cc(40)] Unhandled Exception: GoogleSignInException(code GoogleSignInExceptionCode.providerConfigurationError, getCredentialAsync no provider dependencies found - please ensure the desired provider dependencies are added, null)
E/flutter ( 5416): #0 GoogleSignInAndroid._authenticate (package:google_sign_in_android/google_sign_in_android.dart:231:9)
E/flutter ( 5416): <asynchronous suspension>
E/flutter ( 5416): #1 GoogleSignInAndroid.authenticate (package:google_sign_in_android/google_sign_in_android.dart:93:57)
E/flutter ( 5416): <asynchronous suspension>
E/flutter ( 5416): #2 GoogleSignIn.authenticate (package:google_sign_in/google_sign_in.dart:545:44)
E/flutter ( 5416): <asynchronous suspension>
E/flutter ( 5416):
Device Information
| Field |
Value |
| Android version |
14 (API 34) |
| Google Play Services |
up to date |
google_sign_in version |
7.2.0 |
| Flutter version |
3.44.0 |
code:
import 'package:firebase_core/firebase_core.dart';
import 'package:flutter/material.dart';
import 'package:google_sign_in/google_sign_in.dart';
import 'firebase_options.dart';
Future<void> main() async {
WidgetsFlutterBinding.ensureInitialized();
await Firebase.initializeApp(options: DefaultFirebaseOptions.currentPlatform);
await GoogleSignIn.instance.initialize();
runApp(const MyApp());
}
class MyApp extends StatelessWidget {
const MyApp({super.key});
@override
Widget build(BuildContext context) {
return MaterialApp(
debugShowCheckedModeBanner: true,
title: 'Flutter Demo',
theme: ThemeData(
colorScheme: ColorScheme.fromSeed(seedColor: Colors.deepPurple),
),
home: const MyHomePage(),
);
}
}
class MyHomePage extends StatefulWidget {
const MyHomePage({super.key});
@override
State<MyHomePage> createState() => _MyHomePageState();
}
class _MyHomePageState extends State<MyHomePage> {
@override
Widget build(BuildContext context) {
return Scaffold(
body: Center(
child: Column(
mainAxisAlignment: MainAxisAlignment.center,
children: [
ElevatedButton(
onPressed: () async {
try {
await GoogleSignIn.instance.authenticate();
} catch (e) {
///...
}
},
child: const Text('SIGN IN'),
),
],
),
),
);
}
}
Description
On devices running Android 14, calling
GoogleSignIn.instance.authenticate()(thegoogle_sign_inv7 API)never shows the account picker. A transparent
HiddenActivityfromandroidx.credentials.playservices.controllers.identityauthislaunched and stays alive, which causes the status bar to go dark, but
no bottom sheet or dialog appears. Pressing the system back button
dismisses the
HiddenActivityThe user never saw any UI — they did not cancel anything.
Steps to Reproduce
sdk: ^3.12.0andgoogle_sign_in: ^7.2.0and Firebase.GoogleSignIn.instance.initialize()thenGoogleSignIn.instance.authenticate()on button press.Expected Behavior
The Credential Manager dialog appears and lets the user pick a
Google account.
Actual Behavior
HiddenActivityis shown).GoogleSignInExceptionCode.canceledis thrown.Relevant Log Output
Device Information
google_sign_inversioncode: