Skip to content

Commit 6d9724f

Browse files
committed
store artifacts
1 parent cf4fc4e commit 6d9724f

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed

eval_protocol/pytest/remote_rollout_processor.py

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -122,9 +122,21 @@ async def _process_row(row: EvaluationRow) -> EvaluationRow:
122122
status_logs.append(log)
123123

124124
if status_logs:
125+
if len(status_logs) > 1:
126+
logger.warning(
127+
"Found %s status logs for rollout %s; expected at most 1. Using the first one: %s",
128+
len(status_logs),
129+
row.execution_metadata.rollout_id,
130+
status_logs[0],
131+
)
125132
# Use the first log with status information
126133
status_log = status_logs[0]
127134
status_dict = status_log.get("status")
135+
# Filter out transport metadata fields from extras
136+
raw_extras = status_log.get("extras", {})
137+
status_extras = {
138+
k: v for k, v in raw_extras.items() if k not in ("logger_name", "level", "timestamp")
139+
}
128140

129141
logger.info(
130142
f"Found status log for rollout {row.execution_metadata.rollout_id}: {status_log.get('message', '')}"
@@ -149,6 +161,8 @@ async def _process_row(row: EvaluationRow) -> EvaluationRow:
149161
details=status_details,
150162
)
151163

164+
row.execution_metadata.extra = status_extras
165+
152166
logger.info("Stopping polling for rollout %s", row.execution_metadata.rollout_id)
153167
break
154168

0 commit comments

Comments
 (0)