Archived Content from Web3Auth Community
This topic was originally posted by thomas1 on 6/28/2023.
This content has been migrated from our previous community forum to preserve valuable discussions.
The login flow using the web3auth.login function is failing specifically on Android devices, showing the following error message: â[Web3Auth] login flow failed with error type dismissâ. Itâs worth noting that the same functionality works flawlessly on iOS, and the ID token obtained from Google also works without any problems.
I have thoroughly reviewed the documentation and explored possible reasons for this issue, including permissions, configuration settings, and any platform-specific limitations. However, I have not been able to identify the root cause.
- Android device tested: Pixel 3a API 32 arm64 v8a
- Android API level: 11
- Relevant library versions:
âreact-native-google-signin/google-signinâ: â^10.0.1â,
âtoruslabs/react-native-web-browserâ: â^1.1.0â,
âweb3auth/react-native-sdkâ: â^3.1.0â, - SDK Version: 3.1.0
- Expo or Bare Version: bare
useEffect(() => {
GoogleSignin.configure({
scopes: [],
webClientId: WEB_CLIENT_ID,
offlineAccess: true,
});
}, []);
const signInWeb3Auth = async () => { const idToken = await signInWithGoogle();const clientId = 'example'; const network = OPENLOGIN_NETWORK.CYAN; const web3auth = new Web3Auth(WebBrowser, { clientId, network, }); const redirectUrl = "${myscheme}://openlogin"; const state = await web3auth.login({ loginProvider: LOGIN_PROVIDER.GOOGLE, redirectUrl, extraLoginOptions: { id_token: idToken, verifierIdField: "sub", }, }); if (state.privKey === undefined) { throw new Error("No private key"); } return state.privKey;};
If there are any specific code snippets or debug logs that would be helpful, please let me know, and I will be happy to provide them.