New issue 273: Trailing whitespace when printing with price
https://bitbucket.org/blais/beancount/issues/273/trailing-whitespace-when-printing-with

Michael Droogleever:

To reproduce:

```python
>>> from beancount.parser import printer
>>> from beancount.core import data
>>> import datetime as dt
>>> p1 = data.Posting("Account", data.Amount.from_string("10.00 CHF"), None, 
>>> data.Amount.from_string("1 USD"), None, None)
>>> p2 = data.Posting("Account", data.Amount.from_string("-10.00 USD"), None, 
>>> None, None, None)
>>> t = data.Transaction(None, dt.date(2017,1,1), '*', "", "Narration String", 
>>> data.EMPTY_SET, data.EMPTY_SET, [p1, p2])
>>> print(printer.format_entry(t).replace(' ', '~'))
2017-01-01~*~"Narration~String"
~~Account~~~10.00~CHF~@~1~USD
~~Account~~-10.00~USD~~~~~~~~
```

The second posting has trailing whitespace to match  the length of price, but 
this causes a visual warning in many IDEs for trailing whitespace. e.g. in fava.


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

Reply via email to