From 3e5c587e1399e902012d50ebfa95253c7bf93785 Mon Sep 17 00:00:00 2001 From: XianBW <36835909+XianBW@users.noreply.github.com> Date: Thu, 5 Jun 2025 11:29:37 +0800 Subject: [PATCH] refine debug window logic (#936) --- rdagent/log/ui/app.py | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/rdagent/log/ui/app.py b/rdagent/log/ui/app.py index f30098c1..c0ceef7c 100644 --- a/rdagent/log/ui/app.py +++ b/rdagent/log/ui/app.py @@ -843,9 +843,13 @@ if debug: st.write(state.last_msg) if isinstance(state.last_msg.content, list): st.write(state.last_msg.content[0]) + elif isinstance(state.last_msg.content, dict): + st.write(state.last_msg.content) elif not isinstance(state.last_msg.content, str): - st.write(state.last_msg.content.__dict__) - + try: + st.write(state.last_msg.content.__dict__) + except: + st.write(type(state.last_msg.content)) if state.log_path and state.fs is None: refresh()