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
Repository navigation
Timeline: activities from different sources in the same second aren't listed newest first #585
Seen while writing the automations journey test (M12): an email arrives, an automation runs on it and an approval is decided, all within one second. GET /api/v1/activities then lists them as email, automation.ran, approval.waiting, approval.decided, which is oldest first, though the timeline is meant to be newest first.
Likely cause (not confirmed): sources stamp published to the second, and ties across sources fall back to source name and id (events._order does this for followers, oldest first), so the order within a second is arbitrary rather than causal.
Possible fix: break ties by lens.cause depth (an effect after its cause), or keep sub-second times where the source has them.
The journey test checks activities by id rather than by order for now.
Activity