Working with recurring transactions

168 views
Skip to first unread message

Brian Lalor

unread,
Jan 13, 2025, 10:02:52 AM1/13/25
to Beancount
How do folks manage recurring transactions?  I have written a Python script that processes a recurring.beancount file with entries like

    2024-05-30 R "Dividend Paid" "Interest"
        rrule: "RRULE:FREQ=MONTHLY;BYMONTHDAY=-1"
        Assets:Bank:Checking                                                   0.01 USD
        Income:Bank:Checking:Interest

I run that script with a target month and output the result to a per-month ledger file that’s included in my main ledger:

python ../../hacks/generate_recurring.py recurring.beancount 2025-01 > 2025-01.beancount

The result is an entry that looks like

    2025-01-31 R "Dividend Paid" "Interest"
        Assets:Bank:Checking                                                   0.01 USD
        Income:Bank:Checking:Interest

When I get confirmation of the date and amount of a transaction (which may not be exactly on schedule or the same amount every instance), I update the date, amount, and flag. When the transaction clears my bank, I mark it as cleared with the * flag.

This works, but feels kind of clunky.  Although I don’t really love the beangulp importer workflow, it’d be nice to have recurring transactions “imported” as part of that process.  

— 
Brian Lalor (he/him)

Red S

unread,
Jan 15, 2025, 3:22:27 AM1/15/25
to Beancount
I might be missing something, but why not simply import it from your institution?

Else, doesn't it seem like a lot of trouble to insert a transaction when the date and amount are likely incorrect?

Brian Lalor

unread,
Jan 15, 2025, 6:20:05 AM1/15/25
to bean...@googlegroups.com, Beancount

> On Jan 15, 2025, at 3:22 AM, Red S <redst...@gmail.com> wrote:
>
> I might be missing something, but why not simply import it from your institution?

I use my ledger for planning and some amount of budgeting, not just recording what my bank thinks has happened.

> Else, doesn't it seem like a lot of trouble to insert a transaction when the date and amount are likely incorrect?

My current process isn’t ideal, which is why I’m asking what others are doing. Last week got a utility bill with a payment due date of mid-February. Because I use a tool to bulk-generate recurring transactions for a target month, I now have a couple dozen projected transactions for the next 45ish days in my ledger that I don’t want to see when I look in Fava. Yes, I can apply date filters to limit the range, but those transactions are still going to show in other queries unless I limit the end date. It’s just working around those future entries that I’d like to avoid.

Rather than bulk-generating recurring transactions once a month or so, I’d like to import them closer to when they’re projected to land, and avoid duplicates. This probably means working with beangulp, and I’m looking for existing tools or prior art for this type of thing.

Raja R Harinath

unread,
Jan 15, 2025, 9:41:04 AM1/15/25
to bean...@googlegroups.com
Hi,

On Wed, Jan 15, 2025 at 4:50 PM Brian Lalor <bla...@bravo5.org> wrote:

> On Jan 15, 2025, at 3:22 AM, Red S <redst...@gmail.com> wrote:
>
> I might be missing something, but why not simply import it from your institution?

I use my ledger for planning and some amount of budgeting, not just recording what my bank thinks has happened.

Wouldn't these be modelled as Accounts-Receivable and Accounts-Payable.

e.g., instead of beangulp generating

  2025-01-15 * "line noise xxx electric company xxx line noise"
     Assets:IN:Bank -500 INR
     Expenses:Electricity

we could manually enter, or have your budgeting system generate:

  2025-01-01 * "Budget for electricity"
     Liabilities:Payable:Electric-Company -500 INR
      Expenses:Electricity

and then have beangulp generate:

   2025-01-15 * "line noise xxx electric company xxx line noise"
     Assets:IN:Bank -500 INR
     Liabilities:Payable:Electric-Company
  ;; optional, but maybe a good idea?
  2025-01-15 balance Liabilities:Payable:Electric-Company 0 INR

- Hari

Marcus Read

unread,
Jan 15, 2025, 12:01:48 PM1/15/25
to bean...@googlegroups.com
Hi Brian

Sounds like you might find beanahead of interest. It provides for the generation of regular and ad-hoc expected transactions and for their reconciliation with subsequently imported transactions. You can specify the date up to which you want to generate the expected transactions.

Hope it helps!

Cheers
Marcus

--
You received this message because you are subscribed to the Google Groups "Beancount" group.
To unsubscribe from this group and stop receiving emails from it, send an email to beancount+...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/beancount/CAE64f7H8Dd2qK26kwpOBgM3P16J-xhyaTKpwa5u7NkU3OMwv1g%40mail.gmail.com.

Eric Altendorf

unread,
Jan 15, 2025, 1:46:14 PM1/15/25
to bean...@googlegroups.com
On Wed, Jan 15, 2025 at 3:20 AM Brian Lalor <bla...@bravo5.org> wrote:

> On Jan 15, 2025, at 3:22 AM, Red S <redst...@gmail.com> wrote:
>
> I might be missing something, but why not simply import it from your institution?

I use my ledger for planning and some amount of budgeting, not just recording what my bank thinks has happened.

> Else, doesn't it seem like a lot of trouble to insert a transaction when the date and amount are likely incorrect?

My current process isn’t ideal, which is why I’m asking what others are doing.

This is the first time I've heard on this list of anyone using beancount for forward projections.  All the discussion I've seen has been about recording transactions that have actually already happened.  So I suspect there aren't a lot of others doing this sort of thing.

"beanahead" sounds promising though, good luck!
 
Last week got a utility bill with a payment due date of mid-February. Because I use a tool to bulk-generate recurring transactions for a target month, I now have a couple dozen projected transactions for the next 45ish days in my ledger that I don’t want to see when I look in Fava. Yes, I can apply date filters to limit the range, but those transactions are still going to show in other queries unless I limit the end date. It’s just working around those future entries that I’d like to avoid.

Rather than bulk-generating recurring transactions once a month or so, I’d like to import them closer to when they’re projected to land, and avoid duplicates. This probably means working with beangulp, and I’m looking for existing tools or prior art for this type of thing.

--
You received this message because you are subscribed to the Google Groups "Beancount" group.
To unsubscribe from this group and stop receiving emails from it, send an email to beancount+...@googlegroups.com.
Reply all
Reply to author
Forward
0 new messages