chore: config, layout, project history, simulation framework updates
This commit is contained in:
@@ -17,7 +17,8 @@
|
|||||||
"mcp__manual-slop__py_set_var_declaration",
|
"mcp__manual-slop__py_set_var_declaration",
|
||||||
"mcp__manual-slop__py_check_syntax",
|
"mcp__manual-slop__py_check_syntax",
|
||||||
"Bash(timeout 120 uv run:*)",
|
"Bash(timeout 120 uv run:*)",
|
||||||
"Bash(uv run:*)"
|
"Bash(uv run:*)",
|
||||||
|
"mcp__manual-slop__get_git_diff"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"enableAllProjectMcpServers": true,
|
"enableAllProjectMcpServers": true,
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
[ai]
|
[ai]
|
||||||
provider = "gemini"
|
provider = "gemini_cli"
|
||||||
model = "gemini-2.5-flash-lite"
|
model = "gemini-2.5-flash-lite"
|
||||||
temperature = 0.0
|
temperature = 0.0
|
||||||
max_tokens = 8192
|
max_tokens = 8192
|
||||||
@@ -15,7 +15,7 @@ paths = [
|
|||||||
"C:\\projects\\manual_slop\\tests\\artifacts\\temp_livetoolssim.toml",
|
"C:\\projects\\manual_slop\\tests\\artifacts\\temp_livetoolssim.toml",
|
||||||
"C:\\projects\\manual_slop\\tests\\artifacts\\temp_liveexecutionsim.toml",
|
"C:\\projects\\manual_slop\\tests\\artifacts\\temp_liveexecutionsim.toml",
|
||||||
]
|
]
|
||||||
active = "C:\\projects\\manual_slop\\tests\\artifacts\\temp_liveexecutionsim.toml"
|
active = "C:\\projects\\manual_slop\\tests\\artifacts\\temp_livecontextsim.toml"
|
||||||
|
|
||||||
[gui.show_windows]
|
[gui.show_windows]
|
||||||
"Context Hub" = true
|
"Context Hub" = true
|
||||||
@@ -29,8 +29,8 @@ active = "C:\\projects\\manual_slop\\tests\\artifacts\\temp_liveexecutionsim.tom
|
|||||||
"Discussion Hub" = true
|
"Discussion Hub" = true
|
||||||
"Operations Hub" = true
|
"Operations Hub" = true
|
||||||
Theme = true
|
Theme = true
|
||||||
"Log Management" = false
|
"Log Management" = true
|
||||||
Diagnostics = false
|
Diagnostics = true
|
||||||
|
|
||||||
[theme]
|
[theme]
|
||||||
palette = "ImGui Dark"
|
palette = "ImGui Dark"
|
||||||
|
|||||||
@@ -79,7 +79,7 @@ DockId=0x0000000F,2
|
|||||||
|
|
||||||
[Window][Theme]
|
[Window][Theme]
|
||||||
Pos=0,17
|
Pos=0,17
|
||||||
Size=858,824
|
Size=947,824
|
||||||
Collapsed=0
|
Collapsed=0
|
||||||
DockId=0x00000005,1
|
DockId=0x00000005,1
|
||||||
|
|
||||||
@@ -89,14 +89,14 @@ Size=900,700
|
|||||||
Collapsed=0
|
Collapsed=0
|
||||||
|
|
||||||
[Window][Diagnostics]
|
[Window][Diagnostics]
|
||||||
Pos=860,17
|
Pos=949,17
|
||||||
Size=1154,839
|
Size=1326,447
|
||||||
Collapsed=0
|
Collapsed=0
|
||||||
DockId=0x00000010,0
|
DockId=0x00000010,1
|
||||||
|
|
||||||
[Window][Context Hub]
|
[Window][Context Hub]
|
||||||
Pos=0,17
|
Pos=0,17
|
||||||
Size=858,824
|
Size=947,824
|
||||||
Collapsed=0
|
Collapsed=0
|
||||||
DockId=0x00000005,0
|
DockId=0x00000005,0
|
||||||
|
|
||||||
@@ -107,26 +107,26 @@ Collapsed=0
|
|||||||
DockId=0x0000000D,0
|
DockId=0x0000000D,0
|
||||||
|
|
||||||
[Window][Discussion Hub]
|
[Window][Discussion Hub]
|
||||||
Pos=2016,17
|
Pos=2277,17
|
||||||
Size=879,1821
|
Size=1048,811
|
||||||
Collapsed=0
|
Collapsed=0
|
||||||
DockId=0x00000004,0
|
DockId=0x00000012,0
|
||||||
|
|
||||||
[Window][Operations Hub]
|
[Window][Operations Hub]
|
||||||
Pos=860,17
|
Pos=949,17
|
||||||
Size=1154,839
|
Size=1326,447
|
||||||
Collapsed=0
|
Collapsed=0
|
||||||
DockId=0x00000010,1
|
DockId=0x00000010,0
|
||||||
|
|
||||||
[Window][Files & Media]
|
[Window][Files & Media]
|
||||||
Pos=0,843
|
Pos=0,843
|
||||||
Size=858,995
|
Size=947,794
|
||||||
Collapsed=0
|
Collapsed=0
|
||||||
DockId=0x00000006,1
|
DockId=0x00000006,1
|
||||||
|
|
||||||
[Window][AI Settings]
|
[Window][AI Settings]
|
||||||
Pos=0,843
|
Pos=0,843
|
||||||
Size=858,995
|
Size=947,794
|
||||||
Collapsed=0
|
Collapsed=0
|
||||||
DockId=0x00000006,0
|
DockId=0x00000006,0
|
||||||
|
|
||||||
@@ -136,16 +136,16 @@ Size=416,325
|
|||||||
Collapsed=0
|
Collapsed=0
|
||||||
|
|
||||||
[Window][MMA Dashboard]
|
[Window][MMA Dashboard]
|
||||||
Pos=860,858
|
Pos=2277,830
|
||||||
Size=1154,980
|
Size=1048,807
|
||||||
Collapsed=0
|
Collapsed=0
|
||||||
DockId=0x00000011,0
|
DockId=0x00000013,0
|
||||||
|
|
||||||
[Window][Log Management]
|
[Window][Log Management]
|
||||||
Pos=2016,17
|
Pos=2277,17
|
||||||
Size=879,1821
|
Size=1048,811
|
||||||
Collapsed=0
|
Collapsed=0
|
||||||
DockId=0x00000004,1
|
DockId=0x00000012,1
|
||||||
|
|
||||||
[Window][Track Proposal]
|
[Window][Track Proposal]
|
||||||
Pos=709,326
|
Pos=709,326
|
||||||
@@ -153,28 +153,28 @@ Size=262,209
|
|||||||
Collapsed=0
|
Collapsed=0
|
||||||
|
|
||||||
[Window][Tier 1: Strategy]
|
[Window][Tier 1: Strategy]
|
||||||
Pos=860,858
|
Pos=2277,830
|
||||||
Size=1154,980
|
Size=1048,807
|
||||||
Collapsed=0
|
Collapsed=0
|
||||||
DockId=0x00000011,4
|
DockId=0x00000013,1
|
||||||
|
|
||||||
[Window][Tier 2: Tech Lead]
|
[Window][Tier 2: Tech Lead]
|
||||||
Pos=860,858
|
Pos=1687,1038
|
||||||
Size=1154,980
|
Size=588,599
|
||||||
Collapsed=0
|
Collapsed=0
|
||||||
DockId=0x00000011,3
|
DockId=0x00000017,0
|
||||||
|
|
||||||
[Window][Tier 4: QA]
|
[Window][Tier 4: QA]
|
||||||
Pos=860,858
|
Pos=949,1038
|
||||||
Size=1154,980
|
Size=736,599
|
||||||
Collapsed=0
|
Collapsed=0
|
||||||
DockId=0x00000011,2
|
DockId=0x00000016,0
|
||||||
|
|
||||||
[Window][Tier 3: Workers]
|
[Window][Tier 3: Workers]
|
||||||
Pos=860,858
|
Pos=949,466
|
||||||
Size=1154,980
|
Size=1326,570
|
||||||
Collapsed=0
|
Collapsed=0
|
||||||
DockId=0x00000011,1
|
DockId=0x00000014,0
|
||||||
|
|
||||||
[Table][0xFB6E3870,4]
|
[Table][0xFB6E3870,4]
|
||||||
RefScale=13
|
RefScale=13
|
||||||
@@ -199,24 +199,30 @@ Column 2 Weight=1.0000
|
|||||||
Column 3 Weight=1.0000
|
Column 3 Weight=1.0000
|
||||||
|
|
||||||
[Docking][Data]
|
[Docking][Data]
|
||||||
DockNode ID=0x00000008 Pos=3125,170 Size=593,1157 Split=Y
|
DockNode ID=0x00000008 Pos=3125,170 Size=593,1157 Split=Y
|
||||||
DockNode ID=0x00000009 Parent=0x00000008 SizeRef=1029,147 Selected=0x0469CA7A
|
DockNode ID=0x00000009 Parent=0x00000008 SizeRef=1029,147 Selected=0x0469CA7A
|
||||||
DockNode ID=0x0000000A Parent=0x00000008 SizeRef=1029,145 Selected=0xDF822E02
|
DockNode ID=0x0000000A Parent=0x00000008 SizeRef=1029,145 Selected=0xDF822E02
|
||||||
DockSpace ID=0xAFC85805 Window=0x079D3A04 Pos=0,17 Size=2895,1821 Split=Y
|
DockSpace ID=0xAFC85805 Window=0x079D3A04 Pos=0,17 Size=3325,1620 Split=Y
|
||||||
DockNode ID=0x0000000C Parent=0xAFC85805 SizeRef=1362,1041 Split=X Selected=0x5D11106F
|
DockNode ID=0x0000000C Parent=0xAFC85805 SizeRef=1362,1041 Split=X Selected=0x5D11106F
|
||||||
DockNode ID=0x00000003 Parent=0x0000000C SizeRef=1545,1183 Split=X
|
DockNode ID=0x00000003 Parent=0x0000000C SizeRef=2056,1183 Split=X
|
||||||
DockNode ID=0x0000000B Parent=0x00000003 SizeRef=404,1186 Split=Y Selected=0xF4139CA2
|
DockNode ID=0x0000000B Parent=0x00000003 SizeRef=404,1186 Split=Y Selected=0xF4139CA2
|
||||||
DockNode ID=0x00000002 Parent=0x0000000B SizeRef=1029,1119 Split=X Selected=0xF4139CA2
|
DockNode ID=0x00000002 Parent=0x0000000B SizeRef=1029,1119 Split=X Selected=0xF4139CA2
|
||||||
DockNode ID=0x00000007 Parent=0x00000002 SizeRef=858,858 Split=Y Selected=0x8CA2375C
|
DockNode ID=0x00000007 Parent=0x00000002 SizeRef=728,858 Split=Y Selected=0x8CA2375C
|
||||||
DockNode ID=0x00000005 Parent=0x00000007 SizeRef=295,824 Selected=0xF4139CA2
|
DockNode ID=0x00000005 Parent=0x00000007 SizeRef=295,824 Selected=0xF4139CA2
|
||||||
DockNode ID=0x00000006 Parent=0x00000007 SizeRef=295,995 CentralNode=1 Selected=0x7BD57D6A
|
DockNode ID=0x00000006 Parent=0x00000007 SizeRef=295,995 CentralNode=1 Selected=0x7BD57D6A
|
||||||
DockNode ID=0x0000000E Parent=0x00000002 SizeRef=1154,858 Split=Y Selected=0x418C7449
|
DockNode ID=0x0000000E Parent=0x00000002 SizeRef=1326,858 Split=Y Selected=0x418C7449
|
||||||
DockNode ID=0x00000010 Parent=0x0000000E SizeRef=868,545 Selected=0x418C7449
|
DockNode ID=0x00000010 Parent=0x0000000E SizeRef=868,447 Selected=0x418C7449
|
||||||
DockNode ID=0x00000011 Parent=0x0000000E SizeRef=868,636 Selected=0x3AEC3498
|
DockNode ID=0x00000011 Parent=0x0000000E SizeRef=868,1171 Split=Y Selected=0x655BC6E9
|
||||||
DockNode ID=0x00000001 Parent=0x0000000B SizeRef=1029,775 Selected=0x8B4EBFA6
|
DockNode ID=0x00000014 Parent=0x00000011 SizeRef=1469,570 Selected=0x655BC6E9
|
||||||
DockNode ID=0x0000000D Parent=0x00000003 SizeRef=435,1186 Selected=0x363E93D6
|
DockNode ID=0x00000015 Parent=0x00000011 SizeRef=1469,599 Split=X Selected=0x5CDB7A4B
|
||||||
DockNode ID=0x00000004 Parent=0x0000000C SizeRef=879,1183 Selected=0x6F2B5B04
|
DockNode ID=0x00000016 Parent=0x00000015 SizeRef=736,599 Selected=0x5CDB7A4B
|
||||||
DockNode ID=0x0000000F Parent=0xAFC85805 SizeRef=1362,451 Selected=0xDD6419BC
|
DockNode ID=0x00000017 Parent=0x00000015 SizeRef=588,599 Selected=0x390E7942
|
||||||
|
DockNode ID=0x00000001 Parent=0x0000000B SizeRef=1029,775 Selected=0x8B4EBFA6
|
||||||
|
DockNode ID=0x0000000D Parent=0x00000003 SizeRef=435,1186 Selected=0x363E93D6
|
||||||
|
DockNode ID=0x00000004 Parent=0x0000000C SizeRef=1048,1183 Split=Y Selected=0x2C0206CE
|
||||||
|
DockNode ID=0x00000012 Parent=0x00000004 SizeRef=905,811 Selected=0x6F2B5B04
|
||||||
|
DockNode ID=0x00000013 Parent=0x00000004 SizeRef=905,807 Selected=0x3AEC3498
|
||||||
|
DockNode ID=0x0000000F Parent=0xAFC85805 SizeRef=1362,451 Selected=0xDD6419BC
|
||||||
|
|
||||||
;;;<<<Layout_655921752_Default>>>;;;
|
;;;<<<Layout_655921752_Default>>>;;;
|
||||||
;;;<<<HelloImGui_Misc>>>;;;
|
;;;<<<HelloImGui_Misc>>>;;;
|
||||||
|
|||||||
@@ -8,5 +8,5 @@ active = "main"
|
|||||||
|
|
||||||
[discussions.main]
|
[discussions.main]
|
||||||
git_commit = ""
|
git_commit = ""
|
||||||
last_updated = "2026-03-01T22:32:23"
|
last_updated = "2026-03-01T22:58:49"
|
||||||
history = []
|
history = []
|
||||||
|
|||||||
@@ -10,9 +10,9 @@ class AISettingsSimulation(BaseSimulation):
|
|||||||
provider = self.client.get_value("current_provider")
|
provider = self.client.get_value("current_provider")
|
||||||
model = self.client.get_value("current_model")
|
model = self.client.get_value("current_model")
|
||||||
print(f"[Sim] Initial Provider: {provider}, Model: {model}")
|
print(f"[Sim] Initial Provider: {provider}, Model: {model}")
|
||||||
assert provider == "gemini", f"Expected gemini, got {provider}"
|
assert provider == "gemini_cli", f"Expected gemini_cli, got {provider}"
|
||||||
# 2. Switch to another Gemini model
|
# 2. Switch to another Gemini model
|
||||||
other_gemini = "gemini-1.5-flash"
|
other_gemini = "gemini-2.0-flash"
|
||||||
print(f"[Sim] Switching to {other_gemini}...")
|
print(f"[Sim] Switching to {other_gemini}...")
|
||||||
self.client.set_value("current_model", other_gemini)
|
self.client.set_value("current_model", other_gemini)
|
||||||
time.sleep(2)
|
time.sleep(2)
|
||||||
|
|||||||
@@ -22,9 +22,16 @@ class BaseSimulation:
|
|||||||
print(f"\n[BaseSim] Connecting to GUI...")
|
print(f"\n[BaseSim] Connecting to GUI...")
|
||||||
if not self.client.wait_for_server(timeout=5):
|
if not self.client.wait_for_server(timeout=5):
|
||||||
raise RuntimeError("Could not connect to GUI. Ensure it is running with --enable-test-hooks")
|
raise RuntimeError("Could not connect to GUI. Ensure it is running with --enable-test-hooks")
|
||||||
|
self.client.set_value("auto_add_history", True)
|
||||||
|
# Wait for propagation
|
||||||
|
_start = time.time()
|
||||||
|
while time.time() - _start < 5.0:
|
||||||
|
if self.client.get_value("auto_add_history") is True:
|
||||||
|
break
|
||||||
|
time.sleep(0.1)
|
||||||
print("[BaseSim] Resetting session...")
|
print("[BaseSim] Resetting session...")
|
||||||
self.client.click("btn_reset")
|
self.client.click("btn_reset")
|
||||||
time.sleep(0.5)
|
time.sleep(2.0)
|
||||||
git_dir = os.path.abspath(".")
|
git_dir = os.path.abspath(".")
|
||||||
self.project_path = os.path.abspath(f"tests/artifacts/temp_{project_name.lower()}.toml")
|
self.project_path = os.path.abspath(f"tests/artifacts/temp_{project_name.lower()}.toml")
|
||||||
if os.path.exists(self.project_path):
|
if os.path.exists(self.project_path):
|
||||||
@@ -32,10 +39,9 @@ class BaseSimulation:
|
|||||||
print(f"[BaseSim] Scaffolding Project: {project_name}")
|
print(f"[BaseSim] Scaffolding Project: {project_name}")
|
||||||
self.sim.setup_new_project(project_name, git_dir, self.project_path)
|
self.sim.setup_new_project(project_name, git_dir, self.project_path)
|
||||||
# Standard test settings
|
# Standard test settings
|
||||||
self.client.set_value("auto_add_history", True)
|
|
||||||
self.client.set_value("current_provider", "gemini")
|
self.client.set_value("current_provider", "gemini")
|
||||||
self.client.set_value("current_model", "gemini-2.5-flash-lite")
|
self.client.set_value("current_model", "gemini-2.5-flash-lite")
|
||||||
time.sleep(0.2)
|
time.sleep(1.5)
|
||||||
|
|
||||||
def teardown(self) -> None:
|
def teardown(self) -> None:
|
||||||
if self.project_path and os.path.exists(self.project_path):
|
if self.project_path and os.path.exists(self.project_path):
|
||||||
|
|||||||
@@ -6,11 +6,10 @@ from simulation.sim_base import BaseSimulation, run_sim
|
|||||||
class ContextSimulation(BaseSimulation):
|
class ContextSimulation(BaseSimulation):
|
||||||
def run(self) -> None:
|
def run(self) -> None:
|
||||||
print("\n--- Running Context & Chat Simulation ---")
|
print("\n--- Running Context & Chat Simulation ---")
|
||||||
# 1. Test Discussion Creation
|
# 1. Skip Discussion Creation, use 'main'
|
||||||
disc_name = f"TestDisc_{int(time.time())}"
|
print("[Sim] Using existing 'main' discussion")
|
||||||
print(f"[Sim] Creating discussion: {disc_name}")
|
self.sim.switch_discussion("main")
|
||||||
self.sim.create_discussion(disc_name)
|
time.sleep(1.5)
|
||||||
time.sleep(1)
|
|
||||||
# Verify it's in the list
|
# Verify it's in the list
|
||||||
session = self.client.get_session()
|
session = self.client.get_session()
|
||||||
# The session structure usually has discussions listed somewhere, or we can check the listbox
|
# The session structure usually has discussions listed somewhere, or we can check the listbox
|
||||||
@@ -47,6 +46,7 @@ class ContextSimulation(BaseSimulation):
|
|||||||
msg = "What is the current date and time? Answer in one sentence."
|
msg = "What is the current date and time? Answer in one sentence."
|
||||||
print(f"[Sim] Sending message: {msg}")
|
print(f"[Sim] Sending message: {msg}")
|
||||||
self.sim.run_discussion_turn(msg)
|
self.sim.run_discussion_turn(msg)
|
||||||
|
time.sleep(10)
|
||||||
# 4. Verify History
|
# 4. Verify History
|
||||||
print("[Sim] Verifying history...")
|
print("[Sim] Verifying history...")
|
||||||
session = self.client.get_session()
|
session = self.client.get_session()
|
||||||
|
|||||||
@@ -10,6 +10,7 @@ class ToolsSimulation(BaseSimulation):
|
|||||||
msg = "List the files in the current directory."
|
msg = "List the files in the current directory."
|
||||||
print(f"[Sim] Sending message to trigger tool: {msg}")
|
print(f"[Sim] Sending message to trigger tool: {msg}")
|
||||||
self.sim.run_discussion_turn(msg)
|
self.sim.run_discussion_turn(msg)
|
||||||
|
time.sleep(2)
|
||||||
# 2. Wait for AI to execute tool
|
# 2. Wait for AI to execute tool
|
||||||
print("[Sim] Waiting for tool execution...")
|
print("[Sim] Waiting for tool execution...")
|
||||||
time.sleep(5) # Give it some time
|
time.sleep(5) # Give it some time
|
||||||
@@ -21,6 +22,7 @@ class ToolsSimulation(BaseSimulation):
|
|||||||
msg = "Read the first 10 lines of aggregate.py."
|
msg = "Read the first 10 lines of aggregate.py."
|
||||||
print(f"[Sim] Sending message to trigger tool: {msg}")
|
print(f"[Sim] Sending message to trigger tool: {msg}")
|
||||||
self.sim.run_discussion_turn(msg)
|
self.sim.run_discussion_turn(msg)
|
||||||
|
time.sleep(2)
|
||||||
# 5. Wait and Verify
|
# 5. Wait and Verify
|
||||||
print("[Sim] Waiting for tool execution...")
|
print("[Sim] Waiting for tool execution...")
|
||||||
time.sleep(5)
|
time.sleep(5)
|
||||||
@@ -32,7 +34,9 @@ class ToolsSimulation(BaseSimulation):
|
|||||||
# Actually in Gemini history, they might be nested.
|
# Actually in Gemini history, they might be nested.
|
||||||
# But our GUI disc_entries list usually has them as separate entries or
|
# But our GUI disc_entries list usually has them as separate entries or
|
||||||
# they are part of the AI turn.
|
# they are part of the AI turn.
|
||||||
# Let's check if the AI mentions it in its response
|
if not entries:
|
||||||
|
print("[Sim] ERROR: No history entries found after tool execution.")
|
||||||
|
return
|
||||||
last_ai_msg = entries[-1]['content']
|
last_ai_msg = entries[-1]['content']
|
||||||
print(f"[Sim] Final AI Response: {last_ai_msg[:100]}...")
|
print(f"[Sim] Final AI Response: {last_ai_msg[:100]}...")
|
||||||
|
|
||||||
|
|||||||
@@ -23,7 +23,8 @@ class WorkflowSimulator:
|
|||||||
print(f"Creating discussion: {name}")
|
print(f"Creating discussion: {name}")
|
||||||
self.client.set_value("disc_new_name_input", name)
|
self.client.set_value("disc_new_name_input", name)
|
||||||
self.client.click("btn_disc_create")
|
self.client.click("btn_disc_create")
|
||||||
time.sleep(1)
|
self.client.select_list_item('disc_listbox', name)
|
||||||
|
time.sleep(2)
|
||||||
|
|
||||||
def switch_discussion(self, name: str) -> None:
|
def switch_discussion(self, name: str) -> None:
|
||||||
print(f"Switching to discussion: {name}")
|
print(f"Switching to discussion: {name}")
|
||||||
@@ -54,6 +55,8 @@ class WorkflowSimulator:
|
|||||||
session = self.client.get_session()
|
session = self.client.get_session()
|
||||||
entries = session.get('session', {}).get('entries', [])
|
entries = session.get('session', {}).get('entries', [])
|
||||||
user_message = self.user_agent.generate_response(entries)
|
user_message = self.user_agent.generate_response(entries)
|
||||||
|
active_disc = self.client.get_value("active_discussion")
|
||||||
|
print(f"[DEBUG] Current active discussion in GUI: {active_disc}")
|
||||||
print(f"\n[USER]: {user_message}")
|
print(f"\n[USER]: {user_message}")
|
||||||
self.client.set_value("ai_input", user_message)
|
self.client.set_value("ai_input", user_message)
|
||||||
self.client.click("btn_gen_send")
|
self.client.click("btn_gen_send")
|
||||||
@@ -61,6 +64,7 @@ class WorkflowSimulator:
|
|||||||
def wait_for_ai_response(self, timeout: int = 60) -> dict | None:
|
def wait_for_ai_response(self, timeout: int = 60) -> dict | None:
|
||||||
print("Waiting for AI response...", end="", flush=True)
|
print("Waiting for AI response...", end="", flush=True)
|
||||||
start_time = time.time()
|
start_time = time.time()
|
||||||
|
last_print_time = start_time
|
||||||
last_count = len(self.client.get_session().get('session', {}).get('entries', []))
|
last_count = len(self.client.get_session().get('session', {}).get('entries', []))
|
||||||
while time.time() - start_time < timeout:
|
while time.time() - start_time < timeout:
|
||||||
# Check for error status first
|
# Check for error status first
|
||||||
@@ -71,6 +75,9 @@ class WorkflowSimulator:
|
|||||||
time.sleep(1)
|
time.sleep(1)
|
||||||
print(".", end="", flush=True)
|
print(".", end="", flush=True)
|
||||||
entries = self.client.get_session().get('session', {}).get('entries', [])
|
entries = self.client.get_session().get('session', {}).get('entries', [])
|
||||||
|
if time.time() - last_print_time >= 5:
|
||||||
|
print(f"\n[DEBUG] Current total entries: {len(entries)}")
|
||||||
|
last_print_time = time.time()
|
||||||
if len(entries) > last_count:
|
if len(entries) > last_count:
|
||||||
last_entry = entries[-1]
|
last_entry = entries[-1]
|
||||||
if last_entry.get('role') == 'AI' and last_entry.get('content'):
|
if last_entry.get('role') == 'AI' and last_entry.get('content'):
|
||||||
@@ -80,4 +87,6 @@ class WorkflowSimulator:
|
|||||||
print(f"[WARN] AI response appears to contain an error message.")
|
print(f"[WARN] AI response appears to contain an error message.")
|
||||||
return last_entry
|
return last_entry
|
||||||
print("\nTimeout waiting for AI")
|
print("\nTimeout waiting for AI")
|
||||||
|
active_disc = self.client.get_value("active_discussion")
|
||||||
|
print(f"[DEBUG] Active discussion in GUI at timeout: {active_disc}")
|
||||||
return None
|
return None
|
||||||
|
|||||||
Reference in New Issue
Block a user