Description
Caching data in stats/hitcounts.py doesn't work OK, for two reasons.
- Time zone differences: new data is stored for days depending on what timezone the user is in.
- Time format differences: new data on same day when user has different date format then other user accessing the chart on the same day
Steps to reproduce
Access EventStats/HitCounts
- Change your date/time format in preferences
Access EventStats/HitCounts
- Change your time zone in preferences, so you will be on another day
Access EventStats/HitCounts
- Restore your time zone in preferences
Access EventStats/HitCounts
Example
Component selection
- stats/hitcounts.py, function get_data()
Details
MoinMoin Version |
Release 1.5.8 |
OS and Version |
Linux |
Python Version |
2.4.4 |
Server Setup |
|
Server Details |
|
Language you are using the wiki in (set in the browser/UserPreferences) |
en |
Workaround
Disable caching
Discussion
You can fix the date format thing by caching not formatted dates, but time values.
You can fix the time zone thing by always using UTC times, but this means someone in another time zone won't see the correct values for his or her location.
Plan
- Priority:
Assigned to: ThomasWaldmann
Status: fixed in 1.6, see http://hg.moinmo.in/moin/1.6/rev/2e5f0b2dec4e (won't fix in 1.5 as it is a minor issue and there where other changes in hitcounts, caching has no use_pickle in 1.5 either)