Closed Bug 1128785 Opened 11 years ago Closed 10 years ago

Failure to login due to a "needs reauth" state isn't correctly detected by Sync

Categories

(Firefox :: Sync, defect)

defect
Not set
normal
Points:
1

Tracking

()

RESOLVED FIXED
mozilla39
Iteration:
39.1 - 9 Mar
Tracking Status
firefox39 --- fixed

People

(Reporter: markh, Assigned: markh)

Details

Attachments

(1 file)

Sync calls identity.ensureLoggedIn() and this is supposed to cause an exception if the promise rejects. But it doesn't if the promise rejects with no value, and browserid_identity rejects with no value. This patch changes browserid_identity to always reject with an error object. This alone is enough to fix the bug, however, there's also a change to services.js to ensure that if somehow we *still* manage to reject without a value things will still work. IOW, the change to service.js isn't strictly necessary but adds a safety net. The impact of this bug doesn't seem serious - it just causes Sync to attempt to start when it shouldn't due to an auth error - however, the sync itself then "correctly fails" with additional auth errors. So best I can tell, the impact here is log spew and some additional unnecessary requests to the server.
Attachment #8558246 - Flags: review?(rnewman)
Attachment #8558246 - Flags: review?(rnewman) → review+
Assignee: nobody → mhammond
Status: NEW → ASSIGNED
Iteration: --- → 39.1 - 9 Mar
Points: --- → 1
Flags: qe-verify-
Flags: firefox-backlog+
Status: ASSIGNED → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla39
Component: Firefox Sync: Backend → Sync
Product: Cloud Services → Firefox
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: