GNOME Bugzilla – Bug 106242
qif Importer should warn users about dates before 1970
Last modified: 2018-06-29 20:28:32 UTC
When importing qif, the importer handles dates later than 1/1/1970 only. Earlier than that crashes the import process and the main program. For those of us of a certain age, a loud warning in the first import druid window would be helpful. Or better yet, fix the importer.
Do you think you can submit a sample QIF account file? It should be sufficient if it contains only one data set with that specific date. That way, the developers can easily reproduce your problem, and it is much more likely to be fixed soon. Thanks.
Oh, this problem is easily reproducible, so don't worry about supplying a data file. I've changed the summary to be more accurate.
*** Bug 113880 has been marked as a duplicate of this bug. ***
I'll take ownership
Derek- is this a documentation bug? If no, can we change the component to something else?
Yes, it should be documented, but it's not _just_ a documentation bug. GnuCash should not crash when fed dates prior to Jan 1, 1970, so there is a real bug in the code.
*** Bug 128621 has been marked as a duplicate of this bug. ***
*** Bug 134473 has been marked as a duplicate of this bug. ***
I guess this issue still applies to the current SVN code... Derek?
Yeah, it still does.
Created attachment 102718 [details] [review] Proposed patch This patch uses a throw to drop out of the conversion process if a year before 1970 is encountered. The user will see a generic error message, but a more detailed message will be logged along with the Scheme backtrace. Not the most user-friendly, but it sure beats the present state: crashing! It would be better to actually have the druid display a non-generic error message, but that's a much larger change (and bug 509089 would need to be fixed too).
Created attachment 102719 [details] QIF demonstrating the bug
Applied to trunk as r16872. Awaiting backport.
Applied to branches/2.2 as r16892 for GnuCash 2.2.4. Thanks a lot!
GnuCash bug tracking has moved to a new Bugzilla host. This bug has been copied to https://bugs.gnucash.org/show_bug.cgi?id=106242. Please update any external references or bookmarks.