Skip to content
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

compute_returns.py particially ignores -e END_DATE directive #13

Open
gety9 opened this issue Sep 15, 2021 · 0 comments
Open

compute_returns.py particially ignores -e END_DATE directive #13

gety9 opened this issue Sep 15, 2021 · 0 comments

Comments

@gety9
Copy link

gety9 commented Sep 15, 2021

simple.beancount

plugin "beancount.plugins.auto_accounts"
plugin "beancount.plugins.implicit_prices"

2005-01-01 commodity AAA

2021-07-12 * "Buy; AAA"
  Assets:Investing:CSchwab:AAA            579 AAA {68.82 USD, 2021-07-12}
  Assets:Investing:CSchwab:Cash     -39846.78 USD

2021-08-01 price AAA                    61.32 USD
2021-09-01 price AAA                    64.56 USD

conf-simple

investments {
  investment {
    currency: "AAA"
    asset_account: "Assets:Investing:CSchwab:AAA"
    cash_accounts: "Assets:Investing:CSchwab:Cash"
  }
}
groups {
  group {
    name: "AAA"
    investment: "Assets:Investing:CSchwab:AAA"
  }
}

executing compute_returns.py -e 2021-09-01 simple.beancount conf-simple simple we get
e-2019-09-01
Top left box returns (-36.70) and Cash flows date (2021-09-01) are using cut off date as expected.

But last year return (2021) and rolling returns are calculating using date on which command is executed, which is not intuitive.

Plus it makes beangrow require price points counted from day of execution of command which are shown in prices.beancount (2021-09-15, 2021-06-15, etc) which you need to put into your beancount file. And this DAY part of date will always vary. (unless you can always run your command on same day each month) It makes things a bit untidy.

If one makes the rule that his beancount should contain prices for commodities on 1st of each month
2021-07-01, 2021-08-01, 2021-0901, etc then by having fully functional -e 2021-XX-01 you will not see new dates in prices.beancount and won't need to update your main beancount file.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant