Centralize anonymous user upgrade and handle upgrade conflicts

Đang mở
#734 0 bình luận 0 reaction 0 người được giao Xem trên GitHub

Maintainer thường phản hồi trong vòng 6 ngày

Chưa có ai nhận issue này.

Đánh giá

Độ khó
5/5
Thời gian dự kiến
Hơn một tuần
Mức phù hợp với người mới
35/100
Loại issue
Tính năng
Độ rõ ràng
Khá rõ ràng
Mức độ hoạt động
Sôi nổi
Công nghệ
dart, firebase, flutter
Lĩnh vực
authentication, mobile

Hướng nghiên cứu

Start by tracing the anonymous sign-in and provider upgrade flows across Flutter platforms, including the behavior related to #730. Compare how each provider handles linking and where credential-already-in-use is reported. Done means upgrades behave consistently and existing-account conflicts provide enough information for the app to sign in and merge data; the issue names no files or tests.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

auth enhancement oauth
  • Related to #253
  • Related to #730

Problem

Anonymous users are upgraded inconsistently

When a user who signed in anonymously then signs in with a provider, FirebaseUI should link the provider to the anonymous account so their uid and data are kept. Whether that happens currently depends on the provider and platform:

  • On mobile, most providers link the account; Apple did not until #730.
  • Email/password only links on sign-up. Email link only links when upgradeAnonymousUsers is enabled.
  • On web, OAuth providers (Google, Apple, etc.) sign in as a new user instead of linking, so the anonymous user's data is lost. Phone sign-in on web links even when the signed in user is not anonymous.
Returning users can get stuck

If an anonymous user signs in with a provider account that already belongs to another user (for example, a returning user on a new device), linking fails with credential-already-in-use and the sign-in screen shows an error. The user cannot sign in with that provider while signed in anonymously, and the app has no way to recover the sign-in or merge the anonymous user's data.

Expected behaviour

  • Upgrading anonymous users behaves the same for every provider and platform.
  • When the account already exists, the app is given what it needs to sign the user in and merge the anonymous user's data, instead of a dead-end error.
Ngôn ngữ chính
Dart
Star
152
Fork
144
Merge trung bình
17 giờ 49 phút
Pull request đã merge (30 ngày)
3

Chuẩn bị môi trường

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của firebase/FirebaseUI-Flutter

Tất cả issue của firebase/FirebaseUI-Flutter

Issue tương tự

Thêm issue về Dart

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.