Re: Assertion failure in unistring

2023-01-24 Thread Martin Michlmayr
* Tavis Ormandy  [2023-01-25 06:56]:
> Hello! I've been hitting an assertion when experimenting with register 
> formats:

Can you please report this at https://github.com/ledger/ledger/issues

> Maybe this is not the intended solution, should I just average the cost basis 
> and record it as one big lot?

The transaction looks ok to me, but ledger has had some problems with long
transactions; I guess you hit one such problem.

-- 
Martin Michlmayr
https://www.cyrius.com/

-- 

--- 
You received this message because you are subscribed to the Google Groups 
"Ledger" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to ledger-cli+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ledger-cli/Y9DXOkMo95nYu5k1%40jirafa.cyrius.com.


Assertion failure in unistring

2023-01-24 Thread Tavis Ormandy
Hello! I've been hitting an assertion when experimenting with register formats:

$ ledger --file finance.dat reg -F '%12(total)'
Error: Assertion failed in "/build/ledger-SR1_DQ/ledger-3.1.3/src/unistring.h", 
line 72:ledger::unistring::unistring(const string&): len < 1024

It is probably because I was trying to record the purchase of some stock,
followed by some automatic dividend reinvestments, like this (numbers made up):

2023/01/01 Opening Balances
Assets:Investments:Brokerage  10 ABC @ $1
Assets:Investments:Brokerage  20 DEF @ $150.10
Assets:Investments:Brokerage  20 DEF @ $155.10
Assets:Investments:Brokerage  20 DEF @ $160.10
Assets:Investments:Brokerage  0.555 DEF @ $139.86
Assets:Investments:Brokerage  0.555 DEF @ $105.38
Assets:Investments:Brokerage  0.555 DEF @ $106.03
Assets:Investments:Brokerage  0.555 DEF @ $100.43
Assets:Investments:Brokerage  0.555 DEF @ $110.43
Assets:Investments:Brokerage  0.555 DEF @ $167.84
Assets:Investments:Brokerage  0.555 DEF @ $154.28
Assets:Investments:Brokerage  0.555 DEF @ $137.87
Assets:Investments:Brokerage  0.555 DEF @ $167.62
Assets:Investments:Brokerage  0.555 DEF @ $103.49
Assets:Investments:Brokerage  0.555 DEF @ $183.88
Assets:Investments:Brokerage  0.555 DEF @ $164.78
Assets:Investments:Brokerage  0.555 DEF @ $124.15
Assets:Investments:Brokerage  0.555 DEF @ $189.91
Assets:Investments:Brokerage  0.555 DEF @ $165.80
Assets:Investments:Brokerage  0.555 DEF @ $172.87
Assets:Investments:Brokerage  0.555 DEF @ $152.30
Assets:Investments:Brokerage  0.555 DEF @ $175.06
Assets:Investments:Brokerage  0.555 DEF @ $140.07
Assets:Investments:Brokerage  0.555 DEF @ $321.53
Assets:Investments:Brokerage  0.555 DEF @ $173.77
Assets:Investments:Brokerage  0.555 DEF @ $183.37
Assets:Investments:Brokerage  0.555 DEF @ $159.54
Assets:Investments:Brokerage  0.555 DEF @ $107.77
Assets:Investments:Brokerage  0.555 DEF @ $122.80
Assets:Investments:Brokerage  0.555 DEF @ $139.38
Assets:Investments:Brokerage  0.555 DEF @ $134.81
Assets:Investments:Brokerage  0.555 DEF @ $177.23
Equity:Opening Balances

Maybe this is not the intended solution, should I just average the cost basis 
and record it as one big lot?

Thanks, Tavis.

-- 
 _o)$ lynx lock.cmpxchg8b.com
 /\\  _o)  _o)  $ finger tav...@sdf.org
_\_V _( ) _( )  @taviso

-- 

--- 
You received this message because you are subscribed to the Google Groups 
"Ledger" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to ledger-cli+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ledger-cli/tqqjrd%2417f3%241%40ciao.gmane.io.


Re: Two questions about budgeting

2023-01-24 Thread Marcin Borkowski


On 2023-01-24, at 08:52, Marcin Borkowski  wrote:

> Hi all,
>
> as I mentioned previously, I finally decided to finish my booklet about
> Ledger, and I really want to show how to do budgeting with it.
>
> However, I myself cannit grok it.  Please help.
>
> [...]

Hi all,

I figured out (a few) things.  First of all, using ~bal~ instead of
~reg~ helped (as did adding ~--monthly~).  Still, it looks like
there's a bug with ~Daily~ periodic transactions: if I have a ~Daily~
~Food~ expense of 30 PLN, it is only counted towards my budget on days
an actual ~Food~ expense was made.

Is this by design?  If so, how do I get the correct budget?  The
problem with using a ~Monthly~ budget amounts is that they don't tell
me /in the middle of the month/ if I'm ahead or behind -- I hoped
~Daily~ periodic transactions could help with that...

Best,

-- 
Marcin Borkowski
http://mbork.pl

-- 

--- 
You received this message because you are subscribed to the Google Groups 
"Ledger" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to ledger-cli+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ledger-cli/87k01bnsa5.fsf%40mbork.pl.