fix(frontend): Support V1 conversations in MetricsModal (#12678)

Co-authored-by: openhands <openhands@all-hands.dev>
This commit is contained in:
Tim O'Farrell
2026-01-29 15:03:06 -07:00
committed by GitHub
parent 9fb9efd3d2
commit 3d4cb89441
6 changed files with 265 additions and 3 deletions

View File

@@ -711,8 +711,18 @@ async def refresh_conversation(
updated_conversation_info = ConversationInfo.model_validate(response.json())
# TODO: As of writing, ConversationInfo from AgentServer does not have a title to update...
app_conversation_info.updated_at = updated_conversation_info.updated_at
# TODO: This is a temp fix - the agent server is storing metrics in a new format
# We should probably update the data structures and to store / display the more
# explicit metrics
try:
app_conversation_info.metrics = (
updated_conversation_info.stats.get_combined_metrics()
)
except Exception:
_logger.exception('error_updating_conversation_metrics', stack_info=True)
# TODO: Update other appropriate attributes...
await app_conversation_info_service.save_app_conversation_info(