master
quadrismegistus 4 years ago
parent b163c3ac18
commit 3464e2bb57

@ -29,7 +29,7 @@ class TheSwitchboard(FlaskView, Logger):
from comrad.cli.artcode import ART_OLDPHONE4
data_b=requests.data
self.log(f'Incoming call! {ART_OLDPHONE4}: {data_b}')
self.log(f'Incoming call! {ART_OLDPHONE4}')#': {data_b}')
if not data_b:
self.log('empty request!')
@ -39,7 +39,7 @@ class TheSwitchboard(FlaskView, Logger):
resp_data_b = self.op.answer_phone(data_b)
# decode to str
self.log('about to send back -->',resp_data_b)
# self.log('about to send back -->',resp_data_b)
return resp_data_b
# def get(self,data_b64_str_esc):

@ -57,7 +57,7 @@ class TheTelephone(Operator):
# msg_b64 = b64encode(msg_b)
# msg_b64_str = msg_b64.decode()
# self.log(f'''Sending the encrypted content package:\n\n{msg_b64_str}''')
self.log(f'''Sending the encrypted content package:\n\n{msg_b}''')
# self.log(f'''Sending the encrypted content package:\n\n{msg_b}''')
# seal for transport
# msg_b64_str_esc = msg_b64_str.replace('/','_')
@ -66,7 +66,7 @@ class TheTelephone(Operator):
URL = self.api_url + msg_b64_str_esc + '/'
# URL = self.api_url + msg_b64_str_esc + '/'
self.log("DIALING THE OPERATOR:",URL)
# phonecall=await self.comrad_request_async(URL)
@ -83,7 +83,7 @@ class TheTelephone(Operator):
phonecall = await texec(
self.comrad_request_post,
self.api_url,
msg_b64_str_esc
msg_b
)
break
@ -105,7 +105,7 @@ class TheTelephone(Operator):
resp_msg_b = phonecall.data
self.log(f'{self}: Received response from Operator! We got back:\n\n',resp_msg_b)
self.log(f'{self}: Received response from Operator!')# We got back:\n\n',resp_msg_b)
resp_msg_d = pickle.loads(resp_msg_b)
# self.log('unpickled:',resp_msg_d)

Loading…
Cancel
Save