banking-addons-team team mailing list archive
-
banking-addons-team team
-
Mailing list archive
-
Message #00336
lp:~camptocamp/banking-addons/bank-statement-reconcile-70-fix-completion-error-message into lp:banking-addons/bank-statement-reconcile-70
Nicolas Bessi - Camptocamp has proposed merging lp:~camptocamp/banking-addons/bank-statement-reconcile-70-fix-completion-error-message into lp:banking-addons/bank-statement-reconcile-70.
Requested reviews:
Banking Addons Team (banking-addons-team)
For more details, see:
https://code.launchpad.net/~camptocamp/banking-addons/bank-statement-reconcile-70-fix-completion-error-message/+merge/145176
Fix of error message + index out of range
--
https://code.launchpad.net/~camptocamp/banking-addons/bank-statement-reconcile-70-fix-completion-error-message/+merge/145176
Your team Banking Addons Team is requested to review the proposed merge of lp:~camptocamp/banking-addons/bank-statement-reconcile-70-fix-completion-error-message into lp:banking-addons/bank-statement-reconcile-70.
=== modified file 'account_statement_base_completion/statement.py'
--- account_statement_base_completion/statement.py 2012-12-20 13:40:22 +0000
+++ account_statement_base_completion/statement.py 2013-01-28 13:03:33 +0000
@@ -286,6 +286,8 @@
pattern = ".*%s.*" % st_line.label
cr.execute(sql, (pattern,))
result = cr.fetchall()
+ if not result:
+ return res
if len(result) > 1:
raise ErrorTooManyPartner(
_('Line named "%s" (Ref:%s) was matched by more '
@@ -442,9 +444,9 @@
if res:
compl_lines += 1
except ErrorTooManyPartner, exc:
- msg += exc.value + "\n"
+ msg += repr(exc) + "\n"
except Exception, exc:
- msg += exc.value + "\n"
+ msg += repr(exc) + "\n"
# vals = res and res.keys() or False
if res:
vals = res[line.id]
Follow ups