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 345950 - Crash on the File->Properties Menu
Crash on the File->Properties Menu
Status: VERIFIED INVALID
Product: GnuCash
Classification: Other
Component: Business
1.9.x
Other Linux
: High critical
: ---
Assigned To: Derek Atkins
Derek Atkins
: 390960 (view as bug list)
Depends on:
Blocks:
 
 
Reported: 2006-06-26 11:47 UTC by Martin Klaffenboeck
Modified: 2018-06-29 21:08 UTC
See Also:
GNOME target: ---
GNOME version: 2.15/2.16



Description Martin Klaffenboeck 2006-06-26 11:47:37 UTC
Hi there!

I have a crash on the File->Properties menu.  

If I modify the Company Name, it crashes on Ok with this
stack trace:

bash-3.1$ LC_ALL=C gnucash
Backtrace:
In unknown file:
   ?:  0* [apply-cb]
In /usr/share/gnucash/guile-modules/gnucash/gnome-utils.scm:
  29:  1* [gnc:options-scm->kvp #<procedure dispatch #> # # ...]
In /usr/share/gnucash/scm/options.scm:
1471:  2  [scm->kvp #<gw:wcp <gnc:kvp-frame*> 0x84e9948> ("options")]
In unknown file:
    ...
   ?:  3  [hash-for-each #<procedure #f (section hash)> #(() () (#) () ...)]
In /usr/share/guile/site/slib/hashtab.scm:
 120:  4  (do ((i (+ -1 #) (+ -1 i))) ((negative? i)) ...)
 122:  5* [alist-for-each #<procedure #f (section hash)> (("Business" . #))]
In /usr/share/guile/site/slib/alist.scm:
 117:  6  [for-each #<procedure #f (pair)> (("Business" . #(# # # ...)))]
In unknown file:
   ?:  7* [#<procedure #f (pair)> ("Business" . #((#) (#) (#) ...))]
In /usr/share/guile/site/slib/alist.scm:
 117:  8* [#<procedure #f (section hash)> "Business" #((#) (#) (#) () ...)]
In /usr/share/gnucash/scm/options.scm:
1299:  9  [section-for-each #((#) (#) (#) () ...) #<procedure #f (option)>]
In unknown file:
    ...
   ?: 10  [hash-for-each #<procedure #f (name option)> #((#) (#) (#) () ...)]
In /usr/share/guile/site/slib/hashtab.scm:
 120: 11  (do ((i (+ -1 #) (+ -1 i))) ((negative? i)) ...)
 122: 12* [alist-for-each #<procedure #f (name option)> (("Company Name" . #))]
In /usr/share/guile/site/slib/alist.scm:
 117: 13  [for-each #<procedure #f (pair)> (("Company Name" . #))]
In unknown file:
   ?: 14* [#<procedure #f (pair)> ("Company Name" . #)]
In /usr/share/guile/site/slib/alist.scm:
 117: 15* [#<procedure #f #> "Company Name" #]
In /usr/share/gnucash/scm/options.scm:
1295: 16  [#<procedure #f (option)> #("Business" "Company Name" "a" ...)]
    ...
 199: 17  [gnc:kvp-frame-set-slot-path # {"Kla"} #]

/usr/share/gnucash/scm/options.scm:199:20: In procedure exact? in expression (gnc:kvp-frame-set-slot-path f value ...):
/usr/share/gnucash/scm/options.scm:199:20: Wrong type argument in position 1: "Kla"

Or if I modify the locale setting, it crashes ok Ok with
this stack trace:

bash-3.1$ LC_ALL=C gnucash
Backtrace:
In unknown file:
   ?:  0* [apply-cb]
In /usr/share/gnucash/guile-modules/gnucash/gnome-utils.scm:
  29:  1* [gnc:options-scm->kvp #<procedure dispatch #> # # ...]
In /usr/share/gnucash/scm/options.scm:
1471:  2  [scm->kvp #<gw:wcp <gnc:kvp-frame*> 0x8f78f08> ("options")]
In unknown file:
    ...
   ?:  3  [hash-for-each #<procedure #f (section hash)> #(() () (#) () ...)]
In /usr/share/guile/site/slib/hashtab.scm:
 120:  4  (do ((i (+ -1 #) (+ -1 i))) ((negative? i)) ...)
 122:  5* [alist-for-each #<procedure #f (section hash)> (("Business" . #))]
In /usr/share/guile/site/slib/alist.scm:
 117:  6  [for-each #<procedure #f (pair)> (("Business" . #(# # # ...)))]
In unknown file:
   ?:  7* [#<procedure #f (pair)> ("Business" . #((#) (#) (#) ...))]
In /usr/share/guile/site/slib/alist.scm:
 117:  8* [#<procedure #f (section hash)> "Business" #((#) (#) (#) () ...)]
In /usr/share/gnucash/scm/options.scm:
1299:  9  [section-for-each #((#) (#) (#) () ...) #<procedure #f (option)>]
In unknown file:
    ...
   ?: 10  [hash-for-each #<procedure #f (name option)> #((#) (#) (#) () ...)]
In /usr/share/guile/site/slib/hashtab.scm:
 120: 11  (do ((i (+ -1 #) (+ -1 i))) ((negative? i)) ...)
 122: 12* [alist-for-each #<procedure #f (name option)> (("Fancy Date Format" . #))]
In /usr/share/guile/site/slib/alist.scm:
 117: 13  [for-each #<procedure #f (pair)> (("Fancy Date Format" . #))]
In unknown file:
   ?: 14* [#<procedure #f (pair)> ("Fancy Date Format" . #)]
In /usr/share/guile/site/slib/alist.scm:
 117: 15* [#<procedure #f #> "Fancy Date Format" #]
In /usr/share/gnucash/scm/options.scm:
1295: 16  [#<procedure #f (option)> #("Business" "Fancy Date Format" "g" ...)]
    ...
1359: 17  [#<procedure #f #> # #]
1213: 18* [gnc:kvp-frame-set-slot-path # {"ce"} #]

/usr/share/gnucash/scm/options.scm:1213:8: In procedure exact? in expression (gnc:kvp-frame-set-slot-path f (symbol->string #) ...):
/usr/share/gnucash/scm/options.scm:1213:8: Wrong type argument in position 1: "ce"

This does not depend on the LOCALE Setting, I use LC_ALL=C in my backtraces, and it happends in my default locale de_AT also.  And it does also not depend on a button, this happends for apply and ok the same way.

Thanks for your work on this,
Martin
Comment 1 Josh Sled 2006-06-26 15:44:54 UTC
(Adjusting version, targeting, raising sev (crasher=critical).)

I cannot reproduce.  What string value are you entering for the new name?
Comment 2 Martin Klaffenboeck 2006-06-26 16:28:18 UTC
For me this happens with every string, even a single 'K' does this.  I tried also to create a new file for this.

Its 1.9.8 -r 14384.  The fedora core 5 build.

What else can I try for you to help?

Martin
Comment 3 Derek Atkins 2006-06-27 13:14:15 UTC
I cannot reproduce this here.   I'm using r14434 on FC5, so I'm afraid I don't know what you're seeing.

I run:

 gnucash --nofile
 File -> Properties
 Enter [Kla] into the name
 Click OK

And nothing happens.  We really need a way to reproduce this ourselves so we know it's not your environment (i.e., you're not picking up some gnucash-1.8 files).

Other than gnucash-1.9, did you hand-install anything that didn't come from Fedora as an RPM?
Comment 4 Martin Klaffenboeck 2006-06-27 16:49:13 UTC
I did the same as you wrote:

LC_ALL=C gnucash --nofile
File -> Properties
Enter [ddd] into the Company Name
Click OK

quit message:
Backtrace:
In unknown file:
   ?:  0* [apply-cb]
In /usr/share/gnucash/guile-modules/gnucash/gnome-utils.scm:
  29:  1* [gnc:options-scm->kvp #<procedure dispatch #> # # ...]
In /usr/share/gnucash/scm/options.scm:
1471:  2  [scm->kvp #<gw:wcp <gnc:kvp-frame*> 0x9ccc178> ("options")]
In unknown file:
    ...
   ?:  3  [hash-for-each #<procedure #f (section hash)> #(() () (#) () ...)]
In /usr/share/guile/site/slib/hashtab.scm:
 120:  4  (do ((i (+ -1 #) (+ -1 i))) ((negative? i)) ...)
 122:  5* [alist-for-each #<procedure #f (section hash)> (("Business" . #))]
In /usr/share/guile/site/slib/alist.scm:
 117:  6  [for-each #<procedure #f (pair)> (("Business" . #(# # # ...)))]
In unknown file:
   ?:  7* [#<procedure #f (pair)> ("Business" . #((#) (#) (#) ...))]
In /usr/share/guile/site/slib/alist.scm:
 117:  8* [#<procedure #f (section hash)> "Business" #((#) (#) (#) () ...)]
In /usr/share/gnucash/scm/options.scm:
1299:  9  [section-for-each #((#) (#) (#) () ...) #<procedure #f (option)>]
In unknown file:
    ...
   ?: 10  [hash-for-each #<procedure #f (name option)> #((#) (#) (#) () ...)]
In /usr/share/guile/site/slib/hashtab.scm:
 120: 11  (do ((i (+ -1 #) (+ -1 i))) ((negative? i)) ...)
 122: 12* [alist-for-each #<procedure #f (name option)> (("Company Name" . #))]
In /usr/share/guile/site/slib/alist.scm:
 117: 13  [for-each #<procedure #f (pair)> (("Company Name" . #))]
In unknown file:
   ?: 14* [#<procedure #f (pair)> ("Company Name" . #)]
In /usr/share/guile/site/slib/alist.scm:
 117: 15* [#<procedure #f #> "Company Name" #]
In /usr/share/gnucash/scm/options.scm:
1295: 16  [#<procedure #f (option)> #("Business" "Company Name" "a" ...)]
    ...
 199: 17  [gnc:kvp-frame-set-slot-path # {"ddd"} #]

/usr/share/gnucash/scm/options.scm:199:20: In procedure exact? in expression (gnc:kvp-frame-set-slot-path f value ...):
/usr/share/gnucash/scm/options.scm:199:20: Wrong type argument in position 1: "ddd"

To your question about haveing compiled anything from myself?  I comiled some things, but everything with rpmbuild, so you can find my own builds at 
http://kleinerdrache.org/repos/fc5/repodata/  (Ok, all ruby-gnome related things are only stored here.)

The rest comes out from the fedora (but also development and extras-development things), livna, rpmforge, ...  repos.

But if it is environmentspecific, what can I try?

Thanks
Comment 5 Derek Atkins 2006-06-27 17:06:22 UTC
I still cannot reproduce this in my environment.  Nobody else can reproduce it, except for you.  I even tried calling the scheme bindings directly and still no crash:

[warlord@cliodev ~]$ /opt/gnucash-svk/bin/gnucash-env guile
guile> (use-modules (g-wrapped gw-kvp))
guile> (use-modules (gnucash engine))
guile> (define session (gnc:session-new))
guile> (define book (gnc:session-get-book session))
guile> book
#<gw:wcp <gnc:Book*> 0x9e10b68>
guile> (define txn (gnc:transaction-create book))
guile> txn
#<gw:wcp <gnc:Transaction*> 0x9dc57c8>
guile> (define slots (gnc:transaction-get-slots txn))
guile> slots
#<gw:wcp <gnc:kvp-frame*> 0x9dc5868>
guile> (gnc:kvp-frame-set-slot-path slots "ddd" (list "foo" "bar"))
guile> (gnc:kvp-frame-get-slot-path slots (list "foo" "bar"))
"ddd"
guile>

Can you 'rm -rf' your gnucash install tree and then "make distclean" and rebuild?

Unfortunately, since I cannot reproduce it, I cannot debug it.  The code as-written should work just fine, and indeed it has worked fine for years and still works for me.  This particular code has not changed since r7094 on July 7, 2002.
Comment 6 Christian Stimming 2006-07-31 12:39:42 UTC
@Martin: Does this error still occur? Also, you can try to enter the same command as in comment#5 so that this is really only using the scheme bindings. On the other hand if nobody else sees this, then it's probably not related to the gnucash code but instead maybe some guile or g-wrap version issue. Otherwise, we'll probably close this bug as INVALID since it doesn't seem to be a general bug.
Comment 7 Martin Klaffenboeck 2006-07-31 13:35:38 UTC
No, in gnucash-2.0.0 it works.  I think its because I mad a hand installation on my fedora system and the fedora-development gnucash does not work or something.

So its not for you, it may be for fedora, i don't know.

Thanks,
Martin
Comment 8 Christian Stimming 2007-01-02 10:20:04 UTC
*** Bug 390960 has been marked as a duplicate of this bug. ***
Comment 9 John Ralls 2018-06-29 21:08:42 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=345950. Please update any external references or bookmarks.