PR#2944: decode protonmsg props field when loading from db
Merges #2944 https://pagure.io/koji/pull-request/2944
This commit is contained in:
commit
34d1c8eb9e
1 changed files with 5 additions and 0 deletions
|
|
@ -350,6 +350,11 @@ def handle_db_msgs(urls, CONFIG):
|
|||
aliases=('id', 'address', 'props', 'body'),
|
||||
opts={'order': 'id', 'limit': limit})
|
||||
msgs = list(query.execute())
|
||||
for msg in msgs:
|
||||
try:
|
||||
msg['props'] = json.loads(msg['props'])
|
||||
except Exception:
|
||||
LOG.error('Unable to load message from db: %r', msg)
|
||||
if not msgs:
|
||||
return
|
||||
if CONFIG.getboolean('broker', 'test_mode', fallback=False):
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue