Flutter::iOS 多个方案不同的 Firebase 项目
Flutter::iOS Multiple Schemes Different Firebase Projects
我有多个 env 方案设置 dev 和 prod,因此每个 env 都有两个 firebase 项目。我在 iOS 上设置了两个方案 prod 和 dev,并从 link https://www.tengio.com/blog/multiple-firebase-environments-with-flutter/ 开始逐步按照说明进行操作但是当我尝试使用 google 单点登录时,我得到这个错误 Unhandled Exception: PlatformException(google_sign_in, Your app is missing support for the following URL schemes
我错过了什么?
错误日志:
[VERBOSE-2:ui_dart_state.cc(157)] Unhandled Exception: PlatformException(google_sign_in, Your app is missing support for the following URL schemes: com.googleusercontent.apps.xxxxxx-yyyyy, NSInvalidArgumentException)
#0 StandardMethodCodec.decodeEnvelope (package:flutter/src/services/message_codecs.dart:569:7)
#1 MethodChannel.invokeMethod (package:flutter/src/services/platform_channel.dart:321:33)
<asynchronous suspension>
#2 MethodChannel.invokeMapMethod (package:flutter/src/services/platform_channel.dart:349:48)
#3 MethodChannelGoogleSignIn.signIn (package:google_sign_in_platform_interface/src/method_channel_google_sign_in.dart:45:10)
#4 GoogleSignIn._callMethod (package:google_sign_in/google_sign_in.dart:227:42)
<asynchronous suspension>
#5 GoogleSignIn._addMethodCall.<anonymous closure> (package:google_sign_in/google_sign_in.dart:291:16)
#6 _rootRunUnary (dart:async/zone.dart:1134:38)
#7 _CustomZone.runUnary (dart:async/zon<…>
Lost connection to device.
谢谢
我认为你需要得到 REVERSED_CLIENT_ID
在 google-services.json 或 GoogleService-Info.plist 中找到并添加到 URL Schemes 中的 XCode
您可以查看此 link 了解更多详情
我有多个 env 方案设置 dev 和 prod,因此每个 env 都有两个 firebase 项目。我在 iOS 上设置了两个方案 prod 和 dev,并从 link https://www.tengio.com/blog/multiple-firebase-environments-with-flutter/ 开始逐步按照说明进行操作但是当我尝试使用 google 单点登录时,我得到这个错误 Unhandled Exception: PlatformException(google_sign_in, Your app is missing support for the following URL schemes
我错过了什么?
错误日志:
[VERBOSE-2:ui_dart_state.cc(157)] Unhandled Exception: PlatformException(google_sign_in, Your app is missing support for the following URL schemes: com.googleusercontent.apps.xxxxxx-yyyyy, NSInvalidArgumentException)
#0 StandardMethodCodec.decodeEnvelope (package:flutter/src/services/message_codecs.dart:569:7)
#1 MethodChannel.invokeMethod (package:flutter/src/services/platform_channel.dart:321:33)
<asynchronous suspension>
#2 MethodChannel.invokeMapMethod (package:flutter/src/services/platform_channel.dart:349:48)
#3 MethodChannelGoogleSignIn.signIn (package:google_sign_in_platform_interface/src/method_channel_google_sign_in.dart:45:10)
#4 GoogleSignIn._callMethod (package:google_sign_in/google_sign_in.dart:227:42)
<asynchronous suspension>
#5 GoogleSignIn._addMethodCall.<anonymous closure> (package:google_sign_in/google_sign_in.dart:291:16)
#6 _rootRunUnary (dart:async/zone.dart:1134:38)
#7 _CustomZone.runUnary (dart:async/zon<…>
Lost connection to device.
谢谢
我认为你需要得到 REVERSED_CLIENT_ID
在 google-services.json 或 GoogleService-Info.plist 中找到并添加到 URL Schemes 中的 XCode