You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I noticed the "holdings" tab in my fava only shows me the exception quoted below, clicking on "Query" and boiling down a minimal working example blames get_account_sort_key in conjunction with renamed (top-level) accounts.
exception:
$ bean-query mwe.beancount 'SELECT account, account_sortkey(account) '
Traceback (most recent call last):
File "/usr/lib/python3.10/cmd.py", line 214, in onecmd
func =getattr(self, 'do_'+ cmd)
AttributeError: 'BQLShell' object has no attribute 'do_SELECT'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/usr/lib/python3.10/site-packages/beancount/query/shell.py", line 271, in run_parserself.dispatch(statement)
File "/usr/lib/python3.10/site-packages/beancount/query/shell.py", line 251, in dispatchreturn method(statement)
File "/usr/lib/python3.10/site-packages/beancount/query/shell.py", line 416, in on_Select
rtypes, rrows = query_execute.execute_query(c_query,
File "/usr/lib/python3.10/site-packages/beancount/query/query_execute.py", line 282, in execute_query
values = [c_expr(context) for c_expr in c_target_exprs]
File "/usr/lib/python3.10/site-packages/beancount/query/query_execute.py", line 282, in <listcomp>
values = [c_expr(context) for c_expr in c_target_exprs]
File "/usr/lib/python3.10/site-packages/beancount/query/query_env.py", line 421, in __call__
index, name = account_types.get_account_sort_key(context.account_types, args[0])
File "/usr/lib/python3.10/site-packages/beancount/core/account_types.py", line 46, in get_account_sort_keyreturn (account_types.index(get_account_type(account_name)), account_name)
ValueError: tuple.index(x): x not in tuple
The issue is not the renamed root accounts, but the fact that the account names assigned to the root accounts are leaf accounts. Namely, these options are invalid:
I noticed the "holdings" tab in my fava only shows me the exception quoted below, clicking on "Query" and boiling down a minimal working example blames
get_account_sort_key
in conjunction with renamed (top-level) accounts.exception:
MWE:
The text was updated successfully, but these errors were encountered: