GNOME Bugzilla – Bug 101738
OFX import hangs
Last modified: 2018-06-29 20:23:30 UTC
Package: GnuCash Severity: normal Version: CVS Synopsis: OFX import hangs Bugzilla-Product: GnuCash Bugzilla-Component: Import Description: Loading of an OFX file hangs just after opening file. Trace as follows: open("/home/nigel/bank-statements/TITLEYNBRYGLD_Nov_2002.ofx", O_RDONLY|O_LARGEFILE) = 9 gettimeofday({1040487942, 616257}, NULL) = 0 getpid() = 1605 open("/tmp/libofxtmpe8Fgus", O_RDWR|O_CREAT|O_EXCL, 0600) = 10 open("/tmp/libofxtmpe8Fgus", O_WRONLY|O_CREAT|O_TRUNC|O_LARGEFILE, 0664) = 11 rt_sigprocmask(SIG_SETMASK, NULL, [RTMIN], 8) = 0 rt_sigsuspend([] <unfinished ...> --- SIGINT (Interrupt) --- +++ killed by SIGINT +++ Interrupted by a ^C. Process seems to hang in rt_sigsuspend() This started by being intermittant and is now permanent (ie, it happens every time I try to open a file) Looking at the trace, it appears that a file is being opened twice, once with an exclusive lock, which then hangs. ------- Bug moved to this database by unknown@bugzilla.gnome.org 2002-12-21 11:49 ------- Reassigning to the default owner of the component, chris@wilddev.net.
The problem is deeper than this. Looks like a threads bug in the kernel which is causing the hang. I'm running 2.4.18-18.7.x, under Redhat 7.3. I'll do a bit more hunting. Damm, I really like the OFX import mechanism.
Or possibly a problem with gcc. I'm using gcc version 2.96 20000731 (Red Hat Linux 7.3 2.96-113) Is this recent enough?
gcc shouldn't be a problem. Do you think you can send one of your OFX files to Benoit Grégoire <bock@step.polymtl.ca> ? I guess he will happily assist in tracking down this bug.
I have sent an example file to Benoit. We'll see what he comes up with.
This is still there in the latest gnucash CVS (not surprising as it seems to be in the OFX library), however just noting for the record.
Hmm, curiouser and curiouser. I just tried copying the ofx file from my home directory (which is NFS mounted) to the /tmp directory. Its loading fine. Is there anything in the ofx library which is sensitive to whether a file is NFS mounted or not? Does it try to lock the file or something?
OK, some more digging around. The NFS issue was a red herring. I can also make it happen on a local file. It only seems to happen on a OFX file whose loading has previously been aborted due to a crash (bug 101705). If I make a copy of the file and try to open it, that works. Hunting through the net I find similar bug reports related to kernel pthreads support, although none with recent kernels. Why does libofx need thread support? or is this a requirement of OpenSP?
Reverted back to the standard RH7.3 version of openjade (1.3.1-4) and rebuild libofx and gnucash. Imports now OK. Noted that pthreads lib is now no longer pulled in by libofx. This seems to have appeared with openSP 1.5 (which is what I was linking against before). This confirms my impression that this is a threads issue.
Note that this (or a very similar bug) has been reported by someone else on the gnucash-devel list recently. He was running with a very similar environment, ie RH7.3, OpenSP1.5pre18 (I think).
I have the same problem. If I use OpenSP 1.4 or 1.5 gnucash hangs when importing an ofx file, and if I use the version in OpenJade 1.3.1 it doesn't hang, but ofx fails to read the files correctly (with OJ 1.3.1 ofxdump doesn't work, either.) It doesn't hang though :-) OpenSP 1.4 and 1.5 both appear to use pthreads, while OJ 1.3.1's OpenSP doesn't. Nigel: How did you get libofx to work correctly with OpenJade 1.3.1? I'm not using a distro, this machine is pretty much rolled myself from source these days. gcc 2.95.3
Hmm, I just restored OpenJade 1.3.1, rebuilt LibOFX, rebuilt Gnucash (completely, just to make sure) and it started to work. I'm still on RH7.3, but the kernel is up to 2.4.18-27.7.x. From various kernel lists I gleaned that signal handling in pthreads may well still be rather broken. Why OpenSP is using threads is an interesting question, and one I haven't managed to track down an answer to.
Is it worth asking the OpenJade people to take a look at this bug? I'm subscribing to openjade-devel. Do you want to post? You know more about the problem than I do.
I think it's most definitely worth asking the OpenJade people, I never did because I could never reproduce it. Do include libofx-devel@sourceforge in your cc:
Mailing openjade-devel@lists.sourceforge.net now.
I forgot to cc: libofx-devel@sourceforge, sorry.
The OpenJade archives are available at http://sourceforge.net/mailarchive/forum.php?forum=openjade-devel My post is at http://sourceforge.net/mailarchive/forum.php?thread_id=2643241&forum_id=2437
Is this bug still current? Or did it silently go away with any recent openjade, libofx, gnucash?
I have no idea, I could never reproduce it, and haven't heard any news in almost a year. There were major changes in LibOfx in the interim, which may or may not have changed the issue.
I haven't seen it for some time. My personal view is that it was a threads related issue that went away with changes to libofx and/or the kernel upgrading. I'm happy for it to be closed.
All right, so I'm closing it.
I am new to GC, and am experiencing (a version of?) this bug. OSX 10.3.6, GC1.8.9 built from scratch including OFX extension using Fink (what else can I tell you that would be helpful?). When I (try to) import an ofx or qfx file, the "Generic import transaction matcher" window opens but nothing appears in it. Clicking on OK causes the transaction matcher screen to go away, so I wouldn't describe this as causing the import to hang.
(In reply to Ken Gordon from comment #21) > When I (try to) import an ofx or qfx file, the "Generic import transaction > matcher" window opens but nothing appears in it. Clicking on OK causes the > transaction matcher screen to go away, so I wouldn't describe this as causing > the import to hang. This just started happening to me with my portable version of GnuCash! Well almost... clicking the OK button does nothing in my case... It was working last week and now it doesn't work to import OFX or QFX but it will still do QIF. The install that I have on the computer works (same PortableApps version 2.6.17 built from git rev 319375f+ on 2017-07-02) but the one on my thumb drive will not! Haven't changed anything since the last time when it was working and now it doesn't... weird! I don't know how to get the trace; new to this whole bug reporting thing...x_X
GnuCash bug tracking has moved to a new Bugzilla host. This bug has been copied to https://bugs.gnucash.org/show_bug.cgi?id=101738. Please update any external references or bookmarks.