You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[agent_stop] Prevent potential negative duration calculation due to clock skew #338277
In the agent_stop command handler, the duration of an active turn is calculated as: Timestamp::now().as_millisecond() - started_at.as_millisecond()
If minor clock skew occurs between the agent host and client, this subtraction can potentially result in an invalid negative duration value.
Proposed Solution
Add a defensive check during duration calculation to ensure that if started_at appears to be in the future relative to Timestamp::now(), the duration defaults safely to 0.
Activity