Re: RSU Cookbook and Stock Splits

91 views
Skip to first unread message

Jeff Rabinowitz

unread,
Jul 24, 2022, 9:15:34 PM7/24/22
to Beancount
Hi all!

First of all, I'd like to thank Martin for creating Beancount. I'm an occasional user -- but I find the helpers and opinionated tooling very helpful (one of the reasons I switched from ledger and hledger a few years back).

I happen to work at a tech company that recently had a 20:1 stock split, and it's retroactively split all my unvested RSU's as well. I've been trying to figure out how to model this using the cookbooks for RSU's and Stock Trading, but I'm afraid I'm not having much success. References:


Would anyone be able to point out to me what I'm doing wrong? I've already  tried messing with the acquisition dates, using lot names, cost bases, checking bean-doctor context, all without obvious success.

;; example.beancount
option "operating_currency" "USD"

2022-01-01 commodity HOOL
  quote: USD
2022-01-01 commodity HOOL.UNVSET

2022-01-01 open Income:Hooli:Awards        HOOL.UNVEST
2022-01-01 open Assets:Hooli:Unvested:ABC  HOOL.UNVEST

2022-01-01 * "Award"
  Income:Hooli:Awards        -100 HOOL.UNVEST
  Assets:Hooli:Unvested:ABC   100 HOOL.UNVEST

2022-06-01 * "Stock Split"
  Assets:Hooli:Unvested:ABC  -100 HOOL.UNVEST {1.00 USD} @ 100.00 USD
  Assets:Hooli:Unvested:ABC  2000 HOOL.UNVEST {0.05 USD} @ 100.00 USD

$ bean-check example.beancount
example.beancount:14:      No position matches "Posting(account='Assets:Hooli:Unvested:ABC', units=-100 HOOL.UNVEST, cost=CostSpec(number_per=Decimal('1.00'), number_total=None, currency='USD', date=None, label=None, merge=False), price=100.00 USD, flag=None, meta={'filename': 'example.beancount', 'lineno': 15})" against balance (100 HOOL.UNVEST)

   2022-06-01 * "Stock Split"
     Assets:Hooli:Unvested:ABC  -100 HOOL.UNVEST {1.00 USD} @ 100.00 USD
     Assets:Hooli:Unvested:ABC  2000 HOOL.UNVEST {0.05 USD} @ 100.00 USD



Thanks,

Jeff

Martin Blais

unread,
Jul 24, 2022, 9:25:21 PM7/24/22
to Beancount
On Sun, Jul 24, 2022 at 9:15 PM Jeff Rabinowitz <rabinow...@gmail.com> wrote:
Hi all!

First of all, I'd like to thank Martin for creating Beancount. I'm an occasional user -- but I find the helpers and opinionated tooling very helpful (one of the reasons I switched from ledger and hledger a few years back).

I happen to work at a tech company that recently had a 20:1 stock split, and it's retroactively split all my unvested RSU's as well.

Beangler or Beanmazonster?


I've been trying to figure out how to model this using the cookbooks for RSU's and Stock Trading, but I'm afraid I'm not having much success. References:


Would anyone be able to point out to me what I'm doing wrong? I've already  tried messing with the acquisition dates, using lot names, cost bases, checking bean-doctor context, all without obvious success.

;; example.beancount
option "operating_currency" "USD"

2022-01-01 commodity HOOL
  quote: USD
2022-01-01 commodity HOOL.UNVSET

2022-01-01 open Income:Hooli:Awards        HOOL.UNVEST
2022-01-01 open Assets:Hooli:Unvested:ABC  HOOL.UNVEST

2022-01-01 * "Award"
  Income:Hooli:Awards        -100 HOOL.UNVEST
  Assets:Hooli:Unvested:ABC   100 HOOL.UNVEST

The above is correct. You're correctly not attaching cost basis to unvested shares (no P/L to report on unvested awards).
 

2022-06-01 * "Stock Split"
  Assets:Hooli:Unvested:ABC  -100 HOOL.UNVEST {1.00 USD} @ 100.00 USD
  Assets:Hooli:Unvested:ABC  2000 HOOL.UNVEST {0.05 USD} @ 100.00 USD

Oh! Here is the problem. Your unvested units aren't held with a cost basis. Do this instead:

2022-06-01 * "Stock Split"
  Assets:Hooli:Unvested:ABC  -100 HOOL.UNVEST @ 1.00 USD
  Assets:Hooli:Unvested:ABC  2000 HOOL.UNVEST @ 0.05 USD

Hope this helps,

Reply all
Reply to author
Forward
0 new messages