error in advanced portfolio report (svn r16781)

Andrew Sackville-West andrew at swclan.homelinux.org
Wed Jan 2 20:43:14 EST 2008


On Wed, Jan 02, 2008 at 06:14:22PM -0500, David Reiser wrote:
>
> On Jan 2, 2008, at 1:33 PM, Andrew Sackville-West wrote:
>
>> On Wed, Jan 02, 2008 at 02:34:43AM -0500, David Reiser wrote:
>>> When I run the advanced portfolio report, gnucash complains in the
>>> report window:
>>>
>>> Report error
>>> An error occurred while running the report.
>>>
>>> The terminal window says:
>>>
>>
>> ...
>>
>>>  564: 637* (if (same-account? current #) (begin # #))
>>>  565: 638  (begin (set! basis-list #) (if # # #))
>>>  568: 639* (set! basis-list (basis-builder basis-list split-units ...))
>>>  568: 640* [basis-builder #<unspecified> #<<gnc-numeric> num: 8690
>>> denom: 10000> ...]
>>>  235: 641  (cond ((and # #) (case b-method # ...)) ((and # #) (if #
>>> # ...)) ...)
>>>      ...
>>>  243: 642  [list ...
>>>  243: 643*  [cons ...
>>>  243: 644*   [gnc-numeric-add #<<gnc-numeric> num: 8690 denom:
>>> 10000> ...
>>>  244: 645*    [caar #<unspecified>]
>>> /opt/gnucash-svn/share/gnucash/guile-modules/gnucash/report/advanced-
>>> portfolio.scm:244:43: In procedure caar in expression (caar b-list):
>>> /opt/gnucash-svn/share/gnucash/guile-modules/gnucash/report/advanced-
>>> portfolio.scm:244:43: Wrong type argument in position 1: #<unspecified>

...

>
> a few lines above the scm that appeared in the last report, I get:
>
> * 17:59:57 DEBUG <gnc.scm> b-list is ((#<<gnc-numeric> num: 4189799520000 
> denom: 204700000000> . #<<gnc-numeric> num: 72682214900000000 denom: 
> 418979952000000>)) b-units is #<<gnc-numeric> num: 0 denom: 10000> b-value 
> is #<<gnc-numeric> num: 0 denom: 100> b-method is average-basis

You have a txn with no shares and no value in the split that touches
this account. What is the other side of that transaction? What are you
trying to do with that txn? 

It's a real bug, no doubt, but I want to make sure it gets handled
properly -- there is no code to handle that case, duh, so its
<#unspecified>. So if you can find that txn, and tell what it looks
like and what its trying to do, then I can fix it straight-away. 

 
...

>
> Do you want the other 6000 lines, too?

heh. no. I told you it was copious!

A
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
Url : http://lists.gnucash.org/pipermail/gnucash-devel/attachments/20080102/c9c56f5d/attachment.bin 


More information about the gnucash-devel mailing list