Closed Bug 2090906 Opened 6 days ago Closed 3 days ago

Firefox closes after pairing from a scanned pairing link when the app was not already open

Categories

(Firefox for Android :: Accounts and Sync, defect)

All
Android
defect

Tracking

()

RESOLVED FIXED
162 Branch
Tracking Status
firefox162 --- fixed

People

(Reporter: corentin, Assigned: towhite)

References

(Blocks 1 open bug)

Details

(Whiteboard: [fxdroid][android-activation-trust])

Attachments

(1 external file)

Steps to reproduce

Mobile

  1. Install Firefox for Android
  2. Complete the onboarding
  3. Close Firefox completely
  4. Optional steps for debug builds to enable App Links:
  • Open system settings
  • Click Apps
  • Click Default apps
  • Click Opening links
  • Select Firefox Fenix
  • Click Add link
  • Enable accounts.firefox.com

Desktop
5. Open Firefox Nightly to access the new pairing QR code
6. Visit https://accounts.firefox.com/pair/authority/scan_qr

Mobile
7. Scan the QR code using your system camera app
8. Complete pairing

Expected: The custom tab closes and Firefox stays open.
Actual: The custom tab closes and the user is brought back to the camera app.

Cause
AuthCustomTabActivity runs in its own task because of android:taskAffinity="" and the activity calls finish() when the authentication succeeds. When Firefox was not already running, there is nothing else in Firefox before AuthCustomTabActivity so Android returns to the previous app.

Assignee: nobody → towhite
Status: NEW → ASSIGNED
See Also: → 2091690

AuthCustomTabActivity runs in its own task, so when a pairing link launches Firefox from another app, finishing it on success returns the user to that app instead of Firefox.

Attachment #9679385 - Attachment description: WIP: Bug 2090906 - Open HomeActivity after authenticating from a scanned pairing link. → Bug 2090906 - Open HomeActivity after authenticating from a scanned pairing link.
Pushed by cbect@mozilla.com: https://github.com/mozilla-firefox/firefox/commit/8be9f6660b16 https://hg.mozilla.org/integration/autoland/rev/c84f78cdad49 Open HomeActivity after authenticating from a scanned pairing link. r=android-reviewers,cbect
Status: ASSIGNED → RESOLVED
Closed: 3 days ago
Resolution: --- → FIXED
Target Milestone: --- → 162 Branch
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: