core (memory/sqlite): display arguments in logs in case of too many db/interaction tries
This commit is contained in:
parent
34207a8969
commit
aac5e58ec6
1 changed files with 6 additions and 4 deletions
|
|
@ -150,8 +150,9 @@ class ConnectionPool(adbapi.ConnectionPool):
|
||||||
# Sqlite integration, probably with high level library
|
# Sqlite integration, probably with high level library
|
||||||
retry -= 1
|
retry -= 1
|
||||||
if retry == 0:
|
if retry == 0:
|
||||||
log.error(_(u'too many db tries, we abandon! Error message: {msg}')
|
log.error(_(u'too many db tries, we abandon! Error message: {msg}\n'
|
||||||
.format(msg = e))
|
u'query was {query}'
|
||||||
|
.format(msg=e, query=u' '.join([unicode(a) for a in args]))))
|
||||||
raise e
|
raise e
|
||||||
log.warning(
|
log.warning(
|
||||||
_(u'exception while running query, retrying ({try_}): {msg}').format(
|
_(u'exception while running query, retrying ({try_}): {msg}').format(
|
||||||
|
|
@ -172,8 +173,9 @@ class ConnectionPool(adbapi.ConnectionPool):
|
||||||
retry -= 1
|
retry -= 1
|
||||||
if retry == 0:
|
if retry == 0:
|
||||||
log.error(
|
log.error(
|
||||||
_(u'too many interaction tries, we abandon! Error message: {msg}')
|
_(u'too many interaction tries, we abandon! Error message: {msg}\n'
|
||||||
.format(msg = e))
|
u'interaction was {args}'
|
||||||
|
.format(msg=e, args=u' '.join([unicode(a) for a in args]))))
|
||||||
raise e
|
raise e
|
||||||
log.warning(
|
log.warning(
|
||||||
_(u'exception while running interaction, retrying ({try_}): {msg}')
|
_(u'exception while running interaction, retrying ({try_}): {msg}')
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue