def on_report_to_master(client_id, data):
 data['content-length'] = stats['content-length']
 stats['content-length'] = 0

def on_report_to_master ( client_id , data ) : data [ 'content-length' ] = stats [ 'content-length' ] stats [ 'content-length' ] = 0
this event is triggered on the slave instances every time a stats report is to be sent to the locust master .