redstreet/fava_investor

Per-module list of options / help

Closed this issue · 6 comments

Does a list of arguments for each of the modules exist someplace? Trying to understand a bit more about options are possible and what changes I need to make to my BC file.

Only in code, given how young this project is.

But it's very easy to search for and see all the options in code.

A per-module list of options and what they mean within a help.md file in each module directory would be nice to have. PR appreciated if you go through this. Eventually, this could be turned into online help within the module.

I'm trying the AA pattern "account_open_metadata" but it's failing. Using the example.bc I edited the arguments in the second config of AA by account, and set a tax: metadata equal to 1 on an account open directive.

2010-01-01 custom "fava-extension" "fava_investor" "{
 'tlh' : {
    'account_field': 'account',
    'accounts_pattern': 'Assets:Investments:Taxable',
    'loss_threshold': 50,
    'wash_pattern': 'Assets:Investments',
 },

 'asset_alloc_by_account': [{
     'title':            'Allocation by Account',
     'pattern_type':     'account_name',
     'pattern':          'Assets:Investments:.*',
 },
 {
     'title':            'Allocation by Tax Meta',
     'pattern_type':     'account_open_metadata',
     'pattern':          'tax',
     'metadata_key':     '1',
 }],

 'asset_alloc_by_class' : {
     'accounts_patterns': ['Assets:.*'],
 },
}"

Error message:

 File "/home/pi/beancount/fava_investor/fava_investor/modules/assetalloc_account/libaaacc.py", line 47, in by_account_open_metadata
    for entry in accapi.all_entries_by_type[Open]:
AttributeError: 'FavaInvestorAPI' object has no attribute 'all_entries_by_type'

This is a bug. Would you mind opening a new issue for it?

The bug above should be fixed now.

Main issue (help/doc) still remains open.

Need a README.md in each directory with a list of options, like the one in tlh