New issue 360: invalid beancount file: ValueError: '=' alignment not allowed in 
string format specifier
https://bitbucket.org/blais/beancount/issues/360/invalid-beancount-file-valueerror

Martin Michlmayr:

This invalid file leads to:

```
1970-01-01 open Assets:Cash
1970-01-01 open Equity:Adjustments

2014-04-10 txn "Adjustment"
  Assets:Cash
  Equity:Adjustments
```

```
Traceback (most recent call last):
  File "/home/tbm/.local/bin/bean-check", line 6, in <module>
    sys.exit(main())
  File 
"/home/tbm/.local/lib/python3.5/site-packages/beancount/scripts/check.py", line 
40, in main
    extra_validations=validation.HARDCORE_VALIDATIONS)
  File "/home/tbm/.local/lib/python3.5/site-packages/beancount/loader.py", line 
90, in load_file
    _log_errors(errors, log_errors)
  File "/home/tbm/.local/lib/python3.5/site-packages/beancount/loader.py", line 
128, in _log_errors
    printer.print_errors(errors, file=log_errors)
  File 
"/home/tbm/.local/lib/python3.5/site-packages/beancount/parser/printer.py", 
line 444, in print_errors
    output.write(format_error(error))
  File 
"/home/tbm/.local/lib/python3.5/site-packages/beancount/parser/printer.py", 
line 414, in format_error
    error_string = '\n'.join(format_entry(entry) for entry in entries)
  File 
"/home/tbm/.local/lib/python3.5/site-packages/beancount/parser/printer.py", 
line 414, in <genexpr>
    error_string = '\n'.join(format_entry(entry) for entry in entries)
  File 
"/home/tbm/.local/lib/python3.5/site-packages/beancount/parser/printer.py", 
line 339, in format_entry
    return EntryPrinter(dcontext, render_weights)(entry)
  File 
"/home/tbm/.local/lib/python3.5/site-packages/beancount/parser/printer.py", 
line 117, in __call__
    method(obj, oss)
  File 
"/home/tbm/.local/lib/python3.5/site-packages/beancount/parser/printer.py", 
line 201, in Transaction
    oss.write(fmt(account, position_str))
ValueError: '=' alignment not allowed in string format specifier
```


-- 
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 [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/beancount/20190118011904.33494.64188%40celery-worker-110.ash1.bb-inf.net.
For more options, visit https://groups.google.com/d/optout.

Reply via email to