Subject: | Problem parsing commodities |
Date: | Thu, 25 Jul 2013 19:06:29 +0300 |
To: | bug-Ledger-Parser [...] rt.cpan.org |
From: | Peter Tsolakis <mlsgisanalyst [...] gmail.com> |
I'm using v0.03 of the module, perl is 5.16.2 on windows 8.
Let's say we have the following 4-lines journal:
P 2004/06/21 02:18:01 VIFSX $6.20
2013/07/20 opening balance
asset:stock 100.0000 VIFSX @ $80.5227
equity:opening balance
and our perl script is as simple as it gets:
use 5.010;
use Ledger::Parser;
my $ledgerp = Ledger::Parser->new();
my $journal = $ledgerp->parse_file("$ENV{HOME}/money.dat");
1) It will throw an error while parsing on the 1st line saying "Invalid
pricing syntax"
The syntax is in respect to the official doc
http://ledger-cli.org/3.0/doc/ledger3.html#Commodities-and-Currencies
2) If I comment out the first line of the journal, then a 2nd error is
thrown while parsing the 3rd line saying "Invalid posting syntax". It seems
it can't parse the VIFSX commodity
Thank you!