Issue 8857

Transaction description is blank when importing some OFX files
Nosy list
ced, dave, reviewbot, roundup-bot
Assigned to

Created on 2019-11-22.16:57:53 by dave, last changed 12 months ago by roundup-bot.


New changeset 260e0692b1e4 by C├ędric Krier in branch 'default':
Add unrecognized payees to origin description
New changeset 3f2fdc134660 by David Harper in branch 'default':
Add unrecognized payees to origin description
Author: [hidden] (dave) Tryton committer
Date: 2019-11-22.17:26:05
I think that is a good suggestion.

I was considering reporting the issue upstream, but the spec is rather ambiguous about what the name field should contain, so I'm not too sure how ofxparse could resolve it, plus it doesn't look like there have been any commits to ofxparse since late 2018.
Author: [hidden] (ced) Tryton committer Tryton translator
Date: 2019-11-22.17:09:28
I think the best will be to append the payee to the description if any party was found.
Author: [hidden] (dave) Tryton committer
Date: 2019-11-22.16:57:52
When importing OFX files generated by some banks the description field is not filled in from the OFX data, making it hard for the user to correctly identify the transactions. (e.g:

It appears that the banks are using the name element* inside the stmttrn aggregate* for the description of the transaction.  This is then parsed by ofxparse into the payee field and the memo field is left blank, which results in blank descriptions.

Rather confusingly, the OFX spec ( says (on page 216) the name element* is for the "Name of payee or description of transaction".

Definitions from OFX spec:
*element: a tag that contains only data and no other tags.
*aggregate: a tag that contains other tags and no data.

Examples of parts of OFX data downloaded from two different banks, which don't have the memo element*, and which show the name element* being used for the transaction description:




  <NAME>B/CARD PLAT VISA 123456789012345
  <NAME>Bank credit from XXXXXXXX XXXX</NAME>
Date User Action Args
2019-11-25 11:15:12roundup-botsetmessages: + msg53474
2019-11-25 11:15:05roundup-botsetstatus: testing -> resolved
nosy: + roundup-bot
messages: + msg53473
2019-11-24 13:44:13reviewbotsetmessages: + msg53461
2019-11-24 12:42:11reviewbotsetmessages: + msg53457
2019-11-22 19:03:25reviewbotsetmessages: + msg53434
2019-11-22 18:08:20reviewbotsetnosy: + reviewbot
messages: + msg53431
2019-11-22 18:08:19reviewbotsetreviews: 276391005
keyword: + review
2019-11-22 17:45:54davesetstatus: in-progress -> testing
2019-11-22 17:26:46davesetstatus: unread -> in-progress
assignedto: dave
2019-11-22 17:26:06davesetstatus: chatting -> unread
messages: + msg53429

Showing 10 items. Show all history (warning: this could be VERY long)