GNOME Bugzilla – Bug 150569
OFX/HBCI importer should help the user more not to create Imbalance-XY transactions
Last modified: 2018-06-29 20:46:25 UTC
The OFX importer can create imbalanced transactions. It should never do this. If the user does not supply an account then the importer should use (or create if it does not already exist) an Unspecified account and use that for the balancing split. Gnucash should NEVER create imbalanced transactions.
For the record: The same thing happens on HBCI imports. The reason is in the current implementation of the import-matcher and this would need to be deeply changed in order to fix this. Currently the import-matcher already receives a gnucash-Transaction, no intermediate other data type. The Transaction needs to have an account. If the Transaction should point to some Unspecified account, it would need to exist beforehand -- but in most cases it is needed only temporarily, which means it should not be created as a "normal" gnucash-Account. This can IMHO only be fixed if the import-matcher would receive a new data type (say, ImportTransaction), which only upon hitting "Ok" will be converted to actual gnucash transaction.
Issue still exists in 2.0.x/SVN.
*** Bug 430032 has been marked as a duplicate of this bug. ***
Would it be sufficient to have xaccTransCommitEdit check that the transaction is balanced and do something (destroy transaction, log info and provide dialog message for user) if it isn't? Will all cases where a transaction is created and/or split is added require xaccTransCommitEdit?
Isn't that already implemented with the the call to xaccTransScrubImbalance from xaccTransCommitEdit?
Arguably.. I think the UI makes it too easy to leave it imbalanced. The scrubbing will put it into an IMBALANCE-XXX account, but I think the UI should be more proactive in encouraging users to apply destination accounts to transactions.
... However re-reading my original report I guess technically this bug might be solved, but I still think the UI should be more proactive...
Well, in case of missing destination account the transaction is highlighted with orange background color, so it is clearly visible to the user that something is not quite right. When using the register to enter transactions, it is very easy the skip the destination account with the tab key and there is no feedback at all. The IMBALANCE-XXX account is used as well in this case. I think we can close this bug, if you agree? Or at least lower the priority. :-)
Right. Changing to enhancement.
GnuCash bug tracking has moved to a new Bugzilla host. The new URL for this bug is https://bugs.gnucash.org/show_bug.cgi?id=150569. Please continue processing the bug there and please update any external references or bookmarks.