Skip to content

Commit

Permalink
Merge pull request #472 from NCATSTranslator/fixNormalizerSaveState
Browse files Browse the repository at this point in the history
moved save of sync responses to after pre-processing
  • Loading branch information
MarkDWilliams authored Aug 10, 2023
2 parents 737e2ba + 8aaeca5 commit f7bcdad
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions tr_sys/tr_ars/tasks.py
Original file line number Diff line number Diff line change
Expand Up @@ -117,14 +117,14 @@ def send_message(actor_dict, mesg_dict, timeout=300):
#message_to_merge = utils.get_safe(rdata,"message")
message_to_merge=rdata
agent_name = str(mesg.actor.agent.name)

utils.pre_merge_process(message_to_merge,mesg_dict['pk'], agent_name)
mesg.code = status_code
mesg.status = status
mesg.data = rdata
mesg.url = url
mesg.save()
logger.debug('+++ message saved: %s' % (mesg.pk))
utils.pre_merge_process(message_to_merge,mesg_dict['pk'], agent_name)

if agent_name.startswith('ara-'):
new_merged = utils.merge_received(parent_pk,message_to_merge['message'], agent_name)
utils.post_process(new_merged.data,new_merged.pk, agent_name)
Expand Down

0 comments on commit f7bcdad

Please sign in to comment.