improve debug timeline data and visualization
This commit is contained in:
parent
0774ac8c36
commit
5a3f389bd3
|
@ -39,13 +39,15 @@ const server_message_color = {
|
|||
"allocated": 1, // receive
|
||||
|
||||
"list": 2, // send
|
||||
"channelids": 2, // receive
|
||||
"nameplates": 2, // receive
|
||||
|
||||
"claim": 3, // send
|
||||
"watch": 4, // send
|
||||
"claimed": 3, // receive
|
||||
|
||||
"deallocate": 5, // send
|
||||
"deallocated": 5, // receive
|
||||
"open": 4, // send
|
||||
|
||||
"release": 5, // send
|
||||
"released": 5, // receive
|
||||
|
||||
"error": 6, // receive
|
||||
|
||||
|
@ -62,6 +64,7 @@ const proc_map = {
|
|||
"code established": "code-established",
|
||||
"key established": "key-established",
|
||||
"transit connected": "transit-connected",
|
||||
"print": "print",
|
||||
"exit": "exit",
|
||||
"transit connect": "transit-connect",
|
||||
"import": "import"
|
||||
|
|
|
@ -70,6 +70,7 @@ class Input(object):
|
|||
|
||||
@m.output()
|
||||
def do_start(self):
|
||||
self._start_timing = self._timing.add("input code", waiting="user")
|
||||
self._L.refresh()
|
||||
return Helper(self)
|
||||
@m.output()
|
||||
|
@ -136,6 +137,7 @@ class Input(object):
|
|||
@m.output()
|
||||
def do_words(self, words):
|
||||
code = self._nameplate + "-" + words
|
||||
self._start_timing.finish()
|
||||
self._C.finished_input(code)
|
||||
|
||||
S0_idle.upon(start, enter=S1_typing_nameplate,
|
||||
|
|
|
@ -266,6 +266,7 @@ class Receiver:
|
|||
|
||||
def _handle_text(self, them_d, w):
|
||||
# we're receiving a text message
|
||||
self.args.timing.add("print")
|
||||
print(them_d["message"], file=self.args.stdout)
|
||||
self._send_data({"answer": {"message_ack": "ok"}}, w)
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user