def encode_block(payload, requester, responder):
 assert (len(requester[1].public_key) == PK_LENGTH)
 assert (len(responder[1].public_key) == PK_LENGTH)
 return pack(crawl_response_format, *(payload.up, payload.down, payload.total_up_requester, payload.total_down_requester, payload.sequence_number_requester, payload.previous_hash_requester, payload.total_up_responder, payload.total_down_responder, payload.sequence_number_responder, payload.previous_hash_responder, requester[1].public_key, requester[0], responder[1].public_key, responder[0]))

def encode_block ( payload , requester , responder ) : assert ( len ( requester [ 1 ] . public_key ) == PK_LENGTH ) assert ( len ( responder [ 1 ] . public_key ) == PK_LENGTH ) return pack ( crawl_response_format , * ( payload . up , payload . down , payload . total_up_requester , payload . total_down_requester , payload . sequence_number_requester , payload . previous_hash_requester , payload . total_up_responder , payload . total_down_responder , payload . sequence_number_responder , payload . previous_hash_responder , requester [ 1 ] . public_key , requester [ 0 ] , responder [ 1 ] . public_key , responder [ 0 ] ) )
this function encodes a block .