Skip to content

Commit 4d6dfc8

Browse files
fix(robot-server): Fix analysis log message (#17253)
robot-server logs a message when it begins a protocol analysis. Historically, this happened when, and only when, a client hit the `POST /protocols` endpoint, so the log was placed there. In modern times, it's gotten a little more complicated, and the log has not caught up with that: I think we are logging analyses that do not actually exist. This fixes that.
1 parent 9c6216c commit 4d6dfc8

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

robot-server/robot_server/protocols/router.py

+4-1
Original file line numberDiff line numberDiff line change
@@ -449,7 +449,7 @@ async def _get_cached_protocol_analysis() -> PydanticResponse[
449449
files=[ProtocolFile(name=f.path.name, role=f.role) for f in source.files],
450450
)
451451

452-
log.info(f'Created protocol "{protocol_id}" and started analysis "{analysis_id}".')
452+
log.info(f'Created protocol "{protocol_id}".')
453453

454454
return await PydanticResponse.create(
455455
content=SimpleBody.model_construct(data=data),
@@ -504,6 +504,9 @@ async def _start_new_analysis_if_necessary(
504504
new_parameters=analyzer.get_verified_run_time_parameters(),
505505
)
506506
):
507+
log.info(
508+
f'Starting new analysis "{analysis_id}" for protocol "{protocol_id}".'
509+
)
507510
started_new_analysis = True
508511
analyses.append(
509512
await analyses_manager.start_analysis(

0 commit comments

Comments
 (0)