GNOME Bugzilla – Bug 781171
.log files Timezones are displayed differently on Windows and Linux
Last modified: 2018-06-29 23:55:47 UTC
These .log files -- I've come to realize that the format is completely different between Linux/OSX and Windows Gnucash. Notice the time zones are written correctly in Linux/OSX but not in Windows. This does not seem to effect success of log replay. I initially thought the Windows characters were useful control codes but upon reviewing OSX logs which look neater, realize they must be buggy. This bug probably originates in the boost::date_time library. Not sure how/where Windows obtains TZ from. Linux/OSX: B bc91e801c9ac3cac9db46bb1b24f2b0b e31fb6179fb77006c34e3aa9b402c49a 2017-03-09 14:51:04.000000 +0800 2017-01-14 16:40:49.000000 +0800 2016-06-10 14:59:00.000000 +0800 1c3be17dbaf937f3229d8cd8e0d4de0e etc Windows: D 7237a134a8683615a50ca6a51cfe78e9 3bfa148e30eef2f79d123d4b7df5ef09 2017-03-04 13:35:18.000000 W. AustÝaw 2017-03-04 13:35:18.000000 W. Aust 2017-03-04 14:59:00.000000 W. Aust n 0/1 0/100 1970-01-01 04:00:00.000000 W. Aust8uT
Thanks for your report. You omitted the gnucash version you are using on each platform. Can you add those ?
Windows: these log files were of above format for as long as I remember. And still current 2.6.16 Linux: tested 2.6.13 OSX: tested 2.6.15
Thanks for the feedback. That rules out boost::date_time as the culprit. This library is only used for master at this point, which means in currently unreleased code. It would be interesting to test the opposite though, that is if the new code based on boost::date_time actually resolves the problem. This is currently a bit difficult though because our Windows nightly builds are broken right now due to a dll dependency conflict between mingw and our prebuilt webkitgtk. John's working on getting this fixed.
It won't be boost's fault if it makes a difference. Boost::date_time has a csv file for time zones that the author generated several years ago from the NIST database. I don't think that's a good approach because the OS vendors all maintain current TZ databases. I lifted the TZ code (much of which I co-wrote) from GLib's GTimeZone module and converted it to C++ as GncTimeZone. The reason the TZ indication is different is because g_timespec_to_8601_buf() uses format %Z for Windows and %z for Unix. I don't know why, it's been that way forever. If there's no problem replaying the log files back in to GnuCash why is it a bug?
I believe the log files are a useful changelog for the datafiles and I nowadays do not delete them. I am hoping to parse them to review "what I/someone else entered last week/month". I will try the nightly then they are available.
Gnucash 3.0 .log files on Windows are now identical to Linux.
GnuCash bug tracking has moved to a new Bugzilla host. This bug has been copied to https://bugs.gnucash.org/show_bug.cgi?id=781171. Please update any external references or bookmarks.