Private
Public Access
fix: Robustness improvements for RAG tests and GUI stability
- Added import sys to src/api_hook_client.py. - Fixed App.__getattr__ to use direct attribute access on controller to avoid recursion. - Simplified _get_app_attr and _has_app_attr in src/api_hooks.py. - Centralized RAG and symbol enrichment in AppController._handle_request_event. - Updated ests/test_symbol_parsing.py to match the new enrichment flow. - Removed redundant task appending from i_status and mma_status setters. - Improved _sync_rag_engine to only set 'ready' status after indexing is confirmed. - Updated est_status_encapsulation.py to reflect setter changes.
This commit is contained in:
@@ -27,6 +27,7 @@ def test_rag_large_codebase_verification_sim(live_gui):
|
||||
|
||||
try:
|
||||
# 2. Configure project through Hook API
|
||||
client.set_value('rag_collection_name', 'test_stress')
|
||||
client.set_value('files', file_names)
|
||||
client.set_value('rag_enabled', True)
|
||||
client.set_value('rag_source', 'chroma')
|
||||
@@ -97,14 +98,18 @@ def test_rag_large_codebase_verification_sim(live_gui):
|
||||
|
||||
# Wait for completion
|
||||
success = False
|
||||
status = "unknown"
|
||||
for _ in range(50):
|
||||
state = client.get_gui_state()
|
||||
if state.get('ai_status') == 'done':
|
||||
status = state.get('ai_status', 'unknown')
|
||||
if status == 'done':
|
||||
success = True
|
||||
break
|
||||
if "error" in status.lower():
|
||||
pytest.fail(f"AI request failed with error: {status}")
|
||||
time.sleep(0.5)
|
||||
|
||||
assert success, "AI request timed out"
|
||||
assert success, f"AI request timed out. Final status: {status}"
|
||||
|
||||
# Verify retrieved context in discussion
|
||||
session = client.get_session()
|
||||
|
||||
Reference in New Issue
Block a user