Merge 4310912c745920d7ff287d2eb6dd2dd9a1bf6172 into 42b4a88c963eb480b3c19117c19eac7e146fa8ff

This commit is contained in:
Adam Miller 2025-04-05 22:39:18 +00:00 committed by GitHub
commit 85034b0cf0
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -803,6 +803,12 @@ class Browser:
lambda: self.websock_thread.received_result(msg_id), timeout=5
)
msg = self.websock_thread.pop_result(msg_id)
self.logger.info("Behavior status is %s", str(msg))
# Behavior response while still running
# {'id': 8, 'result': {'result': {'type': 'boolean', 'value': False}}}
# Behavior response when finished
# {'id': 9, 'result': {'result': {'type': 'boolean', 'value': True}}}
if (
msg
and "result" in msg
@ -814,7 +820,10 @@ class Browser:
and isinstance(msg["result"]["result"]["value"], bool)
and msg["result"]["result"]["value"]
):
self.logger.info("behavior decided it has finished")
self.logger.info(
"behavior decided it has finished after %.1fs",
time.time() - start,
)
return
except BrowsingTimeout:
pass