question about warning on stderr

incoming-gnucash at sabot.com incoming-gnucash at sabot.com
Sat May 10 07:28:52 EDT 2014


   To: gnucash-user at gnucash.org
   From: Geert Janssens <janssens-geert at telenet.be>
   Date: Sat, 10 May 2014 11:54:25 +0200
   Subject: Re: question about warning on stderr
   
   On Friday 09 May 2014 18:11:44 incoming-gnucash at sabot.com wrote:
   > I've been running gnucash on my Xubuntu precise machine for a few
   > weeks now, and have (I think) successfully switched myself over from
   > Quicken.  I've accumulated a few questions along the way that I can't
   > answer for myself, but I think it is best to trickle them in one at a
   > time, so I'll start with this:
   > 
   > I'm running what I think is the current version, installed from the
   > getdeb repo into my Xubuntu precise system:
   > 
   >    $ gnucash --version
   >    GnuCash 2.6.3
   >    This copy was built from rev 4e4a032+ on 2014-04-08.
   > 
   > I have been invoking it at the shell, and while the program always
   > behaves fine, there are always warnings being printed out the shell.
   > I'm wondering if these warnings indicate a problem I need to fix in my
   > installation, or if instead they are pretty normal, and I should
   > probably just invoking gnucash by picking it from the application
   > menu or setting up a desktop icon so that this output automatically
   > goes to /dev/nul instead.
   > 
   > For example, every time I run gnucash I see this emitted
   > around startup time:
   > 
   >    Traceback (most recent call last):
   >      File "/usr/share/gnucash/python/init.py", line 3, in <module>
   >        from gnucash import *
   >    ImportError: No module named gnucash
   >    Found Finance::Quote version 1.17
   > 
   This one is harmless if you don't intend to use the python bindings. I 
   suspect This happens because gnucash' python modules are not not found 
   by python. If these modules are not installed in python's default 
   $PYTHONPATH, the path to them should be added instead. This suggests a 
   configuration error in the xubuntu gnucash packages or you may need to 
   install an additional package like gnucash-python or so. I don't know 
   how the Xubuntu packagers decided to set this up exactly.
   
I fired up synaptic and (using the default ubuntu repos) it is
offering me a place to check to load "python-gnucash" (not exactly
gnucash-python?).  Would that install the bindings, making the error
go away (even though I have no plan to use the bindings)?  I see the
version offered is 1:2.4.10-1 from the ubuntu repo, which old, I'll
probably need the 2.6.3-1 version from getdeb which is where I got the
2.6.3 gnucash package.

   > Usually that is all, but on occasion (I think when I do something
   > interesting with reports or qif importing) there are others, such as
   > 
   >    ;;; WARNING (gnc:make-report-anchor:
   > faf410e8f8da481fbc09e4763da40bcc  No such option:  Display Use
   > Stacked Lines)
   > 
   This is harmless as well, but shouldn't happen.
   
   > or
   > 
   >    Backtrace:
   >    In ice-9/boot-9.scm:
   >     149: 4 [catch #t #<catch-closure 145f940> ...]
   >     157: 3 [#<procedure 14cc0f0 ()>]
   >    In unknown file:
   >       ?: 2 [catch-closure]
   >    In qif-import/qif-file.scm:
   >     557: 1 [qif-file:check-from-acct #f]
   >    In ice-9/boot-9.scm:
   >    1091: 0 [#<procedure 1626b40 at ice-9/boot-9.scm:1090:4 (obj)> #f]
   > 
   >    ice-9/boot-9.scm:1091:15: In procedure #<procedure 1626b40 at
   > ice-9/boot-9.scm:1090:4 (obj)>: ice-9/boot-9.scm:1091:15: In
   > procedure struct_vtable: Wrong type argument in position 1 (expecting
   > struct): #f
   > 
   Something goes wrong here while importing a qif file. This is a part of 
   GnuCash I never use so I can't help you here. Does the import fail when 
   you get this error ?
   
For this message, I am looking across the gnucash sessions I used when
converting a handful of small qif files to get myself over from
quicken, so I'm not sure exactly which run caused it: Some of those
runs were experiments to get familiar with gnucash, and some were my
actually moving over.  However, in all of that work, I don't recall
the import ever failing for me.  Possibly I got it for something
innocuous, like naming an incorrect non-qif file to import, and I got
a perfectly reasonable error in the gui as that backtrace got printed
(unnoticed at the time)?

   > or the longer one below:
   > 
   >    In unknown file:
   >       ?: 19 [catch-closure]
   >       ?: 18 [call-with-input-string "(gnc:report-run 2)" ...]
   >    In ice-9/boot-9.scm:
   >    2111: 17 [save-module-excursion #<procedure 42adae0 at
   > ice-9/eval-string.scm:65:9 ()>] In ice-9/eval-string.scm:
   >      44: 16 [read-and-eval #<input: string 19711a0> #:lang ...]
   >      37: 15 [lp (gnc:report-run 2)]
   >    In report.scm:
   >     771: 14 [gnc:report-run 2]
   >    In ice-9/boot-9.scm:
   >     149: 13 [catch ignore #<procedure 42ad8d0 at
   > gnucash/main.scm:112:4 ()> ...] 157: 12 [#<procedure 42875a0 ()>]
   >    In unknown file:
   >       ?: 11 [lazy-catch #t #<procedure 42ad870 at
   > gnucash/main.scm:114:18 ()> ...] In ice-9/boot-9.scm:
   >     171: 10 [with-throw-handler #t #<catch-closure 42aa020>
   > #<catch-closure 42aa000>] In unknown file:
   >       ?: 9 [catch-closure]
   >    In report.scm:
   >     775: 8 [#<procedure 42ad900 at report.scm:772:5 ()>]
   >     746: 7 [gnc:report-render-html # #t]
   >    In gnucash/report/standard-reports/transaction.scm:
   >    1480: 6 [trep-renderer #]
   >    1223: 5 [make-split-table (# # # ...) #<procedure dispatch (key)>
   > ...] 161: 4 [render-account-subheading # # 8 ...]
   >    In html-utilities.scm:
   >      35: 3 [gnc:register-guid "acct-guid=" #f]
   >    In unknown file:
   >       ?: 2 [string-append "acct-guid=" #f]
   >    In ice-9/boot-9.scm:
   >     102: 1 [#<procedure 42a9b80 at ice-9/boot-9.scm:97:6 (thrown-k .
   > args)> wrong-type-arg ...] In unknown file:
   >       ?: 0 [catch-closure wrong-type-arg "string-append" ...]
   >    ERROR: In procedure catch-closure:
   >    ERROR: In procedure string-append: Wrong type (expecting string):
   > #f
   > 
   This one is odd also. Can you provide some steps to reproduce this ?
   
For this one: I have two different gnucash files, one personal and one
business.  They of course each have completely different account
hierarchies.  In each gnucash file, I set up various customized
reports.  I can now replicate this error by running a custom report on
my personal file that I had built/saved out on the business file.  For
example, I have a customized cash flow business report, and invoking
that generate the error.  Similarly for a customized transaction
report.

Along with the backtrace, gnucash has opened a new report tab which
says:

   Report error

   An error occurred while running the report.

When I run the stock cash flow or transaction report on the personal
file, those work fine.  Interestingly, the stock income statement
works fine, but running the customized one (again, customized on the
business file and run on the personal file) does not generate the
backtrace or error.  However, the display report is incorrect, just
showing 0 for income/expense.  

I guess when I saw that there was one set of customized reports, saved
as part of the user settings rather than inside the gnucash file, I
assumed customized reports were meant to applicable to any gnucash
file.  This may not make much sense when the account hierarchies are
different (apologies if this is user error and I'm overlooking
something in the documentation).  Possibly a report could intersect
the available accounts in the current gnucash file with the accounts
in the customized report, give a warning about the extra ones and
soldier on in some fashion?

--gary

   



More information about the gnucash-user mailing list