From 4a6a517dead65928523d2ff62d6cb86211ca7705 Mon Sep 17 00:00:00 2001 From: eLBati Date: Tue, 20 Feb 2018 12:41:56 +0100 Subject: [PATCH] FIX account_bank_statement_import_camt error message and comment --- account_bank_statement_import_camt/models/parser.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/account_bank_statement_import_camt/models/parser.py b/account_bank_statement_import_camt/models/parser.py index fedc386..c6b75e3 100644 --- a/account_bank_statement_import_camt/models/parser.py +++ b/account_bank_statement_import_camt/models/parser.py @@ -232,14 +232,14 @@ class CamtParser(models.AbstractModel): r'|^ISO:camt.052.)' ) if not re_camt_version.search(ns): - raise ValueError('no camt 052 or 053: ' + ns) + raise ValueError('no camt 052 or 053 or 054: ' + ns) # Check GrpHdr element: root_0_0 = root[0][0].tag[len(ns) + 2:] # strip namespace if root_0_0 != 'GrpHdr': raise ValueError('expected GrpHdr, got: ' + root_0_0) def parse(self, data): - """Parse a camt.052 or camt.053 file.""" + """Parse a camt.052 or camt.053 or camt.054 file.""" try: root = etree.fromstring( data, parser=etree.XMLParser(recover=True))