<commit_before>import base64
import Client
def send_log(recieving, master, keystream, ciphertext, plaintext):
	   vals = {
	   "CLK" : clock.uint,
	   "BD_ADDR" : ID.hex,
	   "is_receiving" : recieving,
	   "keystream" : base64.b64encode(keystream.bytes),
	   "ciphertext" : base64.b64encode(ciphertext.bytes),
	   "plaintext" : plaintext.bytes,
	   "timestamp" : '22nd janudary' }

	   Client.postTo('localhost', '8000', 'log', vals, 'POST', 'master' if master else 'slave')
<commit_msg>Now pretty prints date in message<commit_after>import base64
import Client
import datetime
def send_log(recieving, master, keystream, ciphertext, plaintext):
     d = datetime.now()
	   vals = {
	   "CLK" : clock.uint,
	   "BD_ADDR" : ID.hex,
	   "is_receiving" : recieving,
	   "keystream" : base64.b64encode(keystream.bytes),
	   "ciphertext" : base64.b64encode(ciphertext.bytes),
	   "plaintext" : plaintext.bytes,
	   "timestamp" : d.strftime("[%b %d %H:%M:%S]") }

	   Client.postTo('localhost', '8000', 'log', vals, 'POST', 'master' if master else 'slave')

{'fraction_non_alphanumeric': 0.15413891531874405, 'fraction_numerical': 0.028544243577545196, 'mean_word_length': 4.233830845771144, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '383449', 'n_tokens_mistral': 421, 'n_tokens_neox': 367, 'n_words': 82}