Closed
Bug 631233
Opened 14 years ago
Closed 14 years ago
Python server returns records with a 'modified' value same as the 'newer' parameter
Categories
(Cloud Services Graveyard :: Server: Sync, defect)
Tracking
(Not tracked)
RESOLVED
FIXED
People
(Reporter: st3fan, Assigned: tarek)
Details
(Whiteboard: [qa-])
Attachments
(2 files, 2 obsolete files)
17.95 KB,
patch
|
telliott
:
review+
|
Details | Diff | Splinter Review |
2.59 KB,
patch
|
telliott
:
review+
|
Details | Diff | Splinter Review |
The following request:
http://sa.tk:5000/1.0/2d6xkt6ofzsb7xqqwxeffkm7wsqygorv/storage/history?full=1&newer=1296746835.09
Returns the following records:
DEBUG WBO: {'sortindex': 2000, 'payload': ..., 'modified': Decimal('1296746835.09'), 'id': 'TBpVOawXJ2sN'}
DEBUG WBO: {'sortindex': 100, 'payload': ..., 'modified': Decimal('1296746835.09'), 'id': '9_MnuCkjj5kU'}
DEBUG WBO: {'sortindex': 100, 'payload': ..., 'modified': Decimal('1296746835.09'), 'id': 'peaB_KC_N4Hi'}
(The actual amount is 12 records. I did not show them all)
Expected result is only records that are newer than 1296746835.09
The above is the parsed JSON, but I have verified that the timestamps in the original response data are exactly the same.
Assignee | ||
Comment 1•14 years ago
|
||
Might be related to the rounding strategy. (round up/down)
Will add a test case and eventually fix it
Assignee: nobody → tarek
Assignee | ||
Comment 2•14 years ago
|
||
Attachment #509594 -
Flags: review?(telliott)
Attachment #509594 -
Flags: feedback?(sarentz)
Updated•14 years ago
|
Attachment #509594 -
Flags: review?(telliott) → review+
Assignee | ||
Comment 3•14 years ago
|
||
So... I found other spots where we're using float to represent time in the app. So the patch needs more work.
Working on this today -- Should have a patch sometime this CET afternoon.
Assignee | ||
Comment 4•14 years ago
|
||
We want to catch decimal-specific errror and have a valuerror, which is a more standard/global conversion error.
Attachment #509743 -
Flags: review?(telliott)
Assignee | ||
Comment 5•14 years ago
|
||
Completes patch 5095594 - fixed the batch timestamp in the process
Attachment #509775 -
Flags: review?(telliott)
Assignee | ||
Comment 6•14 years ago
|
||
Attachment #509743 -
Attachment is obsolete: true
Attachment #509776 -
Flags: review?(telliott)
Attachment #509743 -
Flags: review?(telliott)
Assignee | ||
Comment 7•14 years ago
|
||
Forget about the first patch - <DELETE attachment 5095594> :)
Assignee | ||
Updated•14 years ago
|
Attachment #509594 -
Attachment is obsolete: true
Attachment #509594 -
Flags: feedback?(sarentz)
Reporter | ||
Comment 8•14 years ago
|
||
I'm not in the patch feedback list. But, I just appllied these patches and syncing works fine for me. The timestamps in the WBOs look good too. So I think think is all good.
Updated•14 years ago
|
Attachment #509776 -
Flags: review?(telliott) → review+
Comment 9•14 years ago
|
||
Comment on attachment 509775 [details] [diff] [review]
Removed all float representation of time
Took me forever to figure out where request.server_time was coming from, but it's fine.
I would suggest that round_time take a value representing number of decimal places, only because I expect a function with the profile round_time(time) to give me an integer. That's just a naming thing and not a blocker.
Attachment #509775 -
Flags: review?(telliott) → review+
Assignee | ||
Comment 10•14 years ago
|
||
(In reply to comment #9)
> Comment on attachment 509775 [details] [diff] [review]
> Removed all float representation of time
>
> Took me forever to figure out where request.server_time was coming from, but
> it's fine.
>
> I would suggest that round_time take a value representing number of decimal
> places, only because I expect a function with the profile round_time(time) to
> give me an integer. That's just a naming thing and not a blocker.
Sure, I can add a precision option.
Assignee | ||
Comment 11•14 years ago
|
||
Done in :
- http://hg.mozilla.org/services/server-core/rev/7a316f98b6ed
- http://hg.mozilla.org/services/server-storage/rev/0b8c9f1ab1c3
Status: NEW → RESOLVED
Closed: 14 years ago
Resolution: --- → FIXED
Updated•14 years ago
|
Whiteboard: [qa-]
Updated•2 years ago
|
Product: Cloud Services → Cloud Services Graveyard
You need to log in
before you can comment on or make changes to this bug.
Description
•