-
Niklas Hambuechen authored
The semantics change in the SlotMap simplification (commit 7a3aa19f) purposely made `hasSlotsFor`/`occupySlots` reject keys that were not in the SlotMap, for example [] `hasSlotsFor` [("key", 1)] == False Unfortunately, I forgot to adjust the `initSlotMap` in `reasonRateLimit`: While before it was allowed to start empty (`occupySlots` would create the slots on the fly), commit 7a3aa19f should have changed it to start with all keys present and set to all buckets unoccupied. This led to all jobs with a `rate-limit:n:...` reason to be rate-limited unconditionally (they were never run). This commit fixes it by adjusting `initSlotMap` as described above. Signed-off-by: Niklas Hambuechen <niklash@google.com> Reviewed-by: Klaus Aehlig <aehlig@google.com>
234a9b71