Browse Source
The ofx files have the correct charset inside their headers and trying to convert the file to StringIO using a particular encoding is subject to failures when the file isn't exactly an ascii file. For example a file encoded with CP1252 with accents on letters like é or è will not be parser as utf-8 and will fail to load. Also since OfxParse is supposed to receive a file handle, it is correctly reading the file header and choosing the appropriate charset to read the rest of the file. For this reason, pass the bytes as a ByteIO that doesn't care about the encoding.pull/200/head
Loïc Faure-Lacroix
6 years ago
committed by
Benjamin
1 changed files with 1 additions and 1 deletions
Loading…
Reference in new issue