comparison src/mam.py @ 401:907b10480394

mam: fixed confusion between twisted log.msg and log.warning used elsewhere
author Goffi <goffi@goffi.org>
date Tue, 07 May 2019 09:15:20 +0200
parents 2521c53bc359
children
comparison
equal deleted inserted replaced
400:371e72871e19 401:907b10480394
118 if page_max >= count: 118 if page_max >= count:
119 # the maximum items which can be displayed is equal to or 119 # the maximum items which can be displayed is equal to or
120 # above the total number of items, which means we are complete 120 # above the total number of items, which means we are complete
121 attributes['complete'] = "true" 121 attributes['complete'] = "true"
122 else: 122 else:
123 log.warning(u"no <first> element in RSM request: {xml}".format( 123 log.msg("WARNING: no <first> element in RSM request: {xml}".format(
124 xml = rsm_elt.toXml())) 124 xml = rsm_elt.toXml().encode('utf-8')))
125 elif item_data.item.name == 'item': 125 elif item_data.item.name == 'item':
126 msg_data.append([item_data.item['id'], make_message(item_data.item), 126 msg_data.append([item_data.item['id'], make_message(item_data.item),
127 item_data.created]) 127 item_data.created])
128 else: 128 else:
129 log.msg("WARNING: unknown element: {}".format(item_data.item.name)) 129 log.msg("WARNING: unknown element: {}".format(item_data.item.name))