-
-
Notifications
You must be signed in to change notification settings - Fork 322
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
register command csv output amount column missing commodity when amount is zero #810
Comments
Thanks for the report. I don't know if this is a bug.. you will probably see the same in console output ? Generally we consider 0 to be commodityless (it could be any or all commodities, how would you know ?) Though, I do remember some change in this area to fix the charts in hledger-web. |
Another way to say it: hledger doesn't know or enforce that certain accounts might contain only a particular commodity. |
I thought you would know because a user specifically told it what commodity it was in the hledger transaction? i.e.
I see that in such cases that
The current behaviour lead to an annoying extra row when I computed the net worth of the example beancount file in my
|
I thought you would know because a user specifically told it what commodity it was in the hledger transaction? i.e.
Assets:US:Federal:PreTax401k 0.00 IRAUSD
True, we could be expected to remember that.
I had the same problem in hledger-web's chart but apparently resolved it with just a local workaround, f2d9c6e.
|
So, if anyone wants to try making zero amounts better at remembering a commodity symbol (just one, I suppose), I would be interested to test it. I expect it will have some impact, but I'm not sure what. |
This is also true of import, which breaks strict mode. CSV:
(the %quantity value is "0.00") Rule:
Produces:
Resulting in error:
|
@robert-e-davidson3, how does the currency get set for a non-zero transaction ? |
Sorry if this is a duplicate issue but I couldn't find a mention of it. I observe missing commodities in the amount column in the csv output from
hledger register
when the amount is exactly zero.In the third row the amount should be a
0.00 IRAUSD
but is instead0
. Here is the transaction inexample.hledger
:The text was updated successfully, but these errors were encountered: