Repository navigation
Give Drukbox a valid Idempotency-Key for every run id - #840
Merged
czpython merged 1 commit intoOct 6, 2026
Merged
Conversation
DBOS 3 names a scheduled run sched-<name>-<timestamp>, and the timestamp carries +00:00. Drukbox accepts only [A-Za-z0-9_-:.] up to 255 characters, so every scheduled run that needs a sandbox failed before its box existed. A refused key now becomes its accepted characters plus a hash of the whole key; an accepted key is unchanged.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #839.
provisioning_key()keeps a key that Drukbox accepts unchanged. Any other key (a DBOS schedule run id carries+00:00; an id can be longer than 255) becomes its accepted characters plus the first 16 hex digits of its sha256: two run ids never share a key, and a retry of the same run builds the same key and finds its box.Tests
tests/test_provisioning_key.py: a real schedule run id, keys that differ only in a refused character, an accepted key unchanged, a key over 255 characters.sandbox_client.ephemeral(idempotency_key=provisioning_key("sched-…-trigger-2026-10-05T19:26:34.645715+00:00", "probe"))created and released a box; before, the same id got 422.