描述
离线时调用 signInWithRedirect()
或 signInWithPopup()
将引发预期错误 O
{code: "auth/network-request-failed", message: "A network error (such as timeout, interrupted connection or unreachable host) has occurred."}.
但是,返回在线并再次调用 signInWithRedirect()
或 signInWithPopup()
将会抛出相同的错误。之后任何调用这些函数的尝试都会导致相同的错误,除非刷新浏览器。
预期结果
重新上线后,身份验证登录功能正常
实际结果
身份验证引发错误,并在后续尝试中继续这样做
重现步骤
- 离线调用
signInWithRedirect()
或signInWithPopup()
(此处应记录错误:O {code: "auth/network-request-failed", message :“发生网络错误(例如超时、连接中断或无法访问主机)。”}) - 上网
- 调用
signInWithRedirect()
或signInWithPopup()
(每次登录尝试都会出现相同的错误
谁能提供解决方案吗?
最佳答案
此处为 firebaser
我们已经能够通过 signInWithRedirect()
确认此行为。这确实是一个错误。我们将在即将发布的版本中修复它。
更新:此问题应在 version 4.1.3 中修复.
关于即使重新上线后,尝试离线登录时仍会出现 Firebase Auth 错误,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/44545050/