After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 113880 - QIF import should error on pre-1970 dates instead of crashing
QIF import should error on pre-1970 dates instead of crashing
Status: VERIFIED DUPLICATE of bug 106242
Product: GnuCash
Classification: Other
Component: Import - Other
1.8.x
Other Linux
: Normal normal
: ---
Assigned To: Derek Atkins
Derek Atkins
Depends on:
Blocks:
 
 
Reported: 2003-05-28 06:19 UTC by howard_b_golden
Modified: 2018-06-29 20:32 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description howard_b_golden 2003-05-28 06:19:54 UTC
I am importing a QIF file from Quicken 2001. The process crashes while
looking for duplicates. The output is shown below. I would appreciate some
troubleshooting suggestions. Thanks.

bash-2.05b$ gnucash &
[1] 9357
bash-2.05b$ Backtrace:
In unknown file:
   ?:  0* [gnc:group-find-duplicates # #]
In /usr/share/gnucash/scm/qif-import/qif-merge-groups.scm:
  38:  1* (let* (# # # # ...) (if # #) (for-each # new-xtns) ...)
  55:  2* [for-each #<procedure #f (xtn)> (# # # # ...)]
In unknown file:
   ?:  3  (if (null? rest) (letrec ((lp #)) (lp list1)) ...)
    ...
   ?:  4  (begin (f (car l)) (lp (cdr l)))
   ?:  5* [#<procedure #f (xtn)> #<gw:wcp <gnc:Transaction*> 0x8651878>]
In /usr/share/gnucash/scm/qif-import/qif-merge-groups.scm:
  57:  6  (let ((query (gnc:malloc-query))) (set! work-done (+ 1
work-done)) ...)
  73:  7* (let ((date #)) (gnc:query-add-date-match-timepair query #t ...))
  74:  8  [gnc:query-add-date-match-timepair #<gw:wcp <gnc:Query*>
0x876eae0> #t ...
  75:  9*  [decdate (-1 . 0) #(0 0 0 7 0 0 0 0 -1 ...)]
In /usr/share/gnucash/scm/date-utilities.scm:
 151: 10   [moddate #<procedure #f (d1 . ds)> (-1 . 0) #(0 0 0 7 0 0 0 0 -1
...)]
     ...
  36: 11   [gnc:secs->timepair ...
  36: 12*   [car ...
  36: 13*    [mktime #(59 59 15 24 11 69 3 364 -1 ...)]

/usr/share/gnucash/scm/date-utilities.scm:36:28: In procedure mktime in
expression (mktime date):
/usr/share/gnucash/scm/date-utilities.scm:36:28: Success

[1]+  Exit 2                  gnucash
bash-2.05b$
bash-2.05b$
Comment 1 Derek Atkins 2003-05-28 16:32:28 UTC
Remove all transactions with dates prior to 1970 and try again.
Comment 2 howard_b_golden 2003-05-28 17:18:02 UTC
Thanks for prompt reply!

Changing pre-1970 dates to 1970 allowed the import to complete.

It would still help if the problem were explained in an error message,
rather than the current crash.

Is pre-1970 a problem in all of GnuCash or just import? Does GnuCash
only support post-1970? If so, this limit will be a problem for
keeping historical cost data.
Comment 3 Derek Atkins 2003-05-28 17:28:41 UTC
Yes, GnuCash cannot store dates prior to Jan 1, 1970 in any capacity,
due to the way GnuCash stores dates.

So, yea, you can't store historic data that's more than 30 years old.
Sorry.

You're right that it should complain instead of crashing when
importing data with old dates.  I'll leave this open and change the topic.
Comment 4 Derek Atkins 2003-06-11 14:51:17 UTC
Combining duplicate bug reports.

*** This bug has been marked as a duplicate of 106242 ***
Comment 5 John Ralls 2018-06-29 20:32:38 UTC
GnuCash bug tracking has moved to a new Bugzilla host. This bug has been copied to https://bugs.gnucash.org/show_bug.cgi?id=113880. Please update any external references or bookmarks.