implicit_prices plugin should not add a price on transfers

32 views
Skip to first unread message

redst...@gmail.com

unread,
Dec 30, 2020, 1:49:38 AM12/30/20
to Beancount
The last entry below is a transfer of lots from one account to another. The implicit_prices plugin picks up the cost price, which is incorrect. It should instead do nothing, when a price is not specified. I haven't looked deeper into how to distinguish a "true" augmenting transaction vs a lot transfer.

2000-01-01 open Assets:Brokerage:USD
2000-01-01 open Assets:Brokerage:HOOL                            "STRICT"
2000-01-01 open Assets:Zero-Sum-Accounts:Transfers               "STRICT"

2005-01-01 commodity USD
2005-01-01 commodity HOOL

2020-01-01 * "Buy"
  Assets:Brokerage:HOOL   1000 HOOL {1 USD, 2020-01-01}
  Assets:Brokerage:USD   -1000 USD

2020-01-01 price HOOL                                    1 USD
  __implicit_prices__: "from_cost"
2020-10-01 price HOOL                                  1.1 USD

2020-10-02 * "Transfer out, in kind"
  Assets:Brokerage:HOOL               -1000 HOOL {1 USD, 2020-01-01}
  Assets:Zero-Sum-Accounts:Transfers   1000 HOOL {1 USD, 2020-10-02}

2020-10-02 price HOOL                                    1 USD
  __implicit_prices__: "from_cost"

Reply all
Reply to author
Forward
0 new messages