Past "run_at" values now allowed for "event" actions

Previously, a "run_at" value with a past datetime was not permitted for "event" actions. Because Mechanic's run system is not synchronous, this had the potential to cause issues when "run_at" was set to the current time, or to a value within a few seconds of the current time. In those cases, any delay between event creation and the performance of the event run gave rise to a "[time] is in the past, and can't be scheduled" error.

To bring the "run_at" mechanism into alignment with how Mechanic more broadly thinks about time and scheduling, we now allow "run_at" values to be set in the past. When an event is scheduled for the past, it will simply be run immediately, as if no "run_at" value was set.

Read more