Closed Bug 1170707 Opened 9 years ago Closed 9 years ago

connectivity issue during sync sign-in leads to confusing UI state, possible UI hang?

Categories

(Firefox for iOS :: Firefox Accounts, defect)

Other
iOS
defect
Not set
normal

Tracking

()

RESOLVED FIXED
Tracking Status
fxios + ---

People

(Reporter: Gavin, Assigned: nalexander)

References

Details

Attachments

(2 files)

Attached image post sign-in screenshot
I just tried signing in to TestFlight build 19 for the first time. I think what happened is:

1) Entered my username/password (took a while since I had to go look up my password in 1password)
2) The Mountain View wireless is kind of spotty, and as I submitted the sign-in form my internet connection dropped (I was flipping between wifi and LTE)

After this, I got a preferences UI that said "Enter your password to connect" (see screenshot), which was confusing (since I had just done that). I tried tapping that row to see what that was about, but that apparently did nothing. I was only able to dismiss the settings window by hitting the "Done" button, after which I ended up on the tabs screen, and the whole app froze up (no buttons were responsive at all). I assume this could have been caused by the syncing?

It eventually recovered and my sync data appeared without any additional action, and going back to the settings pane showed the normal UI.
tracking-fennec: --- → ?
tracking-fxios: --- → ?
tracking-fennec: ? → +
It's probably obvious, but we need to investigate whether this issue is being caused by anything in our Web content for FxA.
Still visible on Build #24. This is terrible UX.
tracking-fennec: + → ---
(In reply to Aaron Train [:aaronmt] from comment #4)
> Still visible on Build #24. This is terrible UX.

I will try to get to this before I go on PTO this Friday but I'm "a little busy".
Any update here?
Assignee: nobody → nalexander
Component: Sync → Firefox Accounts
Status: NEW → ASSIGNED
I don't think this has anything to do with connectivity issues. It always happens, on both device and in simulator. Looks more like a state / ui out-of-sync issue.
(In reply to Stefan Arentz [:st3fan] from comment #7)
> I don't think this has anything to do with connectivity issues. It always
> happens, on both device and in simulator. Looks more like a state / ui
> out-of-sync issue.

Stefan is correct.  I dug into this and have a patch in the works.

What is happening is that we've grown consumers of FirefoxAccount.advance(), and they're now racing at setup time.  Different parts of the UI start advancing the account.  One of the setup tokens from the fxa-content-server is single use; all advancers that try to reuse it fail.  By the time the successful advancer finishes, parts of the UI have already seen an error (even though the final advance is successful).

rnewman and I discussed how to lock this efficiently; patch inbound.
Comment on attachment 8643203 [details] [review]
Link to Github pull-request: https://github.com/mozilla/firefox-ios/pull/861

st3fan is under water post-PTO, so redirecting to etoop, who has worked in this area.
Attachment #8643203 - Flags: review?(sarentz) → review?(etoop)
Attachment #8643203 - Flags: review?(etoop) → review+
Attachment #8643203 - Flags: review?(rnewman)
Landed with r=etoop,st3fan f=rnewman.

https://github.com/mozilla/firefox-ios/commit/adb0927ed01ed13bad09cae3284eb631d33af281

AaronMT: this could use verification.  It should be as simple as not observing a "PW required" orange error when signing in to an existing Firefox Account.
Status: ASSIGNED → RESOLVED
Closed: 9 years ago
Flags: needinfo?(aaron.train)
Resolution: --- → FIXED
AaronMT: further, any janky syncing or hanging pull-to-refresh, etc, that you observe should start by pointing the finger at this ticket.
(In reply to Nick Alexander :nalexander from comment #12)
> Landed with r=etoop,st3fan f=rnewman.
> 
> https://github.com/mozilla/firefox-ios/commit/
> adb0927ed01ed13bad09cae3284eb631d33af281
> 
> AaronMT: this could use verification.  It should be as simple as not
> observing a "PW required" orange error when signing in to an existing
> Firefox Account.

Aye, looks good

(In reply to Nick Alexander :nalexander from comment #13)
> AaronMT: further, any janky syncing or hanging pull-to-refresh, etc, that
> you observe should start by pointing the finger at this ticket.

There's https://bugzilla.mozilla.org/show_bug.cgi?id=1191925
Flags: needinfo?(aaron.train)
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: