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

Returns: add new option to make verification easier: --configured-accounts-only #2

Open
redstreet opened this issue Jan 25, 2021 · 3 comments

Comments

@redstreet
Copy link

From this doc: After building a basic config file and perhaps making a few simple changes to your ledger, compute_returns.py spits out numbers. How can the correctness of these numbers be verified?

Something that has been tripping me up a lot: an underspecified config. For example:

investment {
  currency "ABCD"
  asset_account: "Assets:Investments:ABCD"
  cash_accounts: "Assets:BankOrange"
  dividend_accounts: "Income:Diidends:ABCD"   ; <-- spelling error causes silent underspecification, and incorrect results
  dividend_accounts: "Income:Interest:ABCD"   ; <-- If I forget to include this line, postings with it are silently ignored
}

The problem is, these are all silent failures unless one examines investments/*.org in the output, of which I have tons, too many to manually inspect.

A --configured-accounts-only would work only if all accounts found in all relevant postings are specified in the config. It could further list all the unspecified accounts. Even better, it could auto-generate a new config with them with a comment for the user to complete specifying them.

@redstreet redstreet changed the title Returns: --non-configured-accounts verification. Returns: add new option to make verification easier: --configured-accounts-only Jan 25, 2021
@blais
Copy link
Member

blais commented Jan 25, 2021

Thanks for the bug reports Red. I have to review the returns code.
Planning to move to its own repo under name "beangrow".

@redstreet
Copy link
Author

Good idea, and I like the name!

I'll probably file more improvement requests/bugs as I find them if that's okay. I plan to work on patches for these when I can find the time.

I've got it up and running for most of my portfolio in the past couple of weeks, and it's been very helpful in providing insights that I've wanted for a long time. Thanks again for writing and sharing this!

@blais blais transferred this issue from beancount/beanlabs Jan 28, 2021
@gety9
Copy link

gety9 commented Sep 13, 2021

Great suggestion by redstreet on "--configured-accounts-only", and in my opinion and should be default setting.
(to make function less error / misspelling prone)

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

3 participants