Closed
Bug 1194499
Opened 9 years ago
Closed 9 years ago
Partial JSON responses muffle NotFound errors; command sends fail on 404
Categories
(Firefox for iOS :: Sync, defect)
Tracking
()
RESOLVED
FIXED
Tracking | Status | |
---|---|---|
fxios | + | --- |
People
(Reporter: rnewman, Assigned: rnewman)
References
Details
Attachments
(1 file)
2015-08-13 13:39:50.042 [Debug] [ClientsSynchronizer.swift:223] maybeUploadOurRecord(_:ifUnmodifiedSince:toServer:): Client record upload succeeded. New timestamp: 1439498389960.
2015-08-13 13:39:50.045 [Info] [SQLiteRemoteClientsAndTabs.swift:335] getCommands(): Found 1 client sync commands in the DB.
2015-08-13 13:39:50.107 [Error] [StorageClient.swift:311] errorWrap(_:handler:): Got error Error Domain=NSCocoaErrorDomain Code=3840 "The operation couldn’t be completed. (Cocoa error 3840.)" (JSON text did not start with array or object and option to allow fragments not set.) UserInfo=0x174473480 {NSDebugDescription=JSON text did not start with array or object and option to allow fragments not set.}. Response: Optional(404)
Assignee | ||
Comment 1•9 years ago
|
||
I suspect this is getting a 404 response in either upload or download of a client record, and the body isn't JSON.
Assignee | ||
Comment 2•9 years ago
|
||
What's happening here is we're getting a JSON parse error, which overrides the 404 handler, so we don't log that.
Assignee | ||
Comment 3•9 years ago
|
||
This breaks command sending to other clients, and also tab sync (which depends on clients).
Assignee: nobody → rnewman
Status: NEW → ASSIGNED
tracking-fxios:
--- → ?
Summary: Malformed JSON… somewhere → Partial JSON responses muffle NotFound errors; command sends fail on 404
Assignee | ||
Comment 4•9 years ago
|
||
Attachment #8647791 -
Flags: review?(sleroux)
Comment 5•9 years ago
|
||
Comment on attachment 8647791 [details] [review]
Pull req.
Code looks good - just some q's
Attachment #8647791 -
Flags: review?(sleroux) → review+
Assignee | ||
Comment 6•9 years ago
|
||
Assignee | ||
Comment 7•9 years ago
|
||
Half way there:
2015-08-13 18:35:04.809 [Debug] [ClientsSynchronizer.swift:239] maybeUploadOurRecord(_:ifUnmodifiedSince:toServer:): Should we upload our client record? Caller = false, expired = false.
2015-08-13 18:35:04.811 [Info] [SQLiteRemoteClientsAndTabs.swift:335] getCommands(): Found 1 client sync commands in the DB.
2015-08-13 18:35:04.813 [Debug] [ClientsSynchronizer.swift:193] syncClientCommands(_:commands:clientsAndTabs:withServer:): Fetching current client record for client Tb40VvFMTUfh.
2015-08-13 18:35:04.874 [Debug] [StorageClient.swift:326] errorWrap(_:handler:): Status code: 404
2015-08-13 18:35:04.875 [Warning] [ClientsSynchronizer.swift:211] syncClientCommands(_:commands:clientsAndTabs:withServer:): Failed to fetch record with GUID Tb40VvFMTUfh.
2015-08-13 18:35:04.875 [Error] [ClientsSynchronizer.swift:226] syncClientCommands(_:commands:clientsAndTabs:withServer:): Client Tb40VvFMTUfh commands upload failed: No remote client for GUID
Now to figure out why the NotFound code block didn't run.
Assignee | ||
Comment 8•9 years ago
|
||
I pushed 3de233f as a follow-up: I changed my mind on whether to throw away or keep trying on 404.
You need to log in
before you can comment on or make changes to this bug.
Description
•