Add runtime identity artifacts for task worktrees#34
Closed
Fuiste wants to merge 4 commits into
Closed
Conversation
Fuiste
commented
Apr 13, 2026
Fuiste
left a comment
Owner
Author
There was a problem hiding this comment.
I found two blocking issues in the runtime identity implementation.
src/night_shift/runtime_identity.gleam:47-57derivesport_basefromsha256_mod(..., 1000), so there are only 1000 possible bases. Because runtime contexts are retained per task, not just used transiently, different tasks in the same run can collide on the same port block. The collision risk is already material well below 1000 tasks (roughly 17% by 20 tasks), so this does not provide the deterministic isolation the feature is aiming for.src/night_shift/runtime_identity.gleam:160-164writesnight-shift.envas rawKEY=VALUElines using absolute paths from the runtime context. If either the repo path or state path contains spaces, the resulting file is not safely sourceable by shell scripts, even though the docs pitch it as a shell/Compose-friendly artifact. The env file needs escaping/quoting rules (or a narrower documented parser contract) before we can rely on it.
Owner
Author
|
Addressed the review in
|
Owner
Author
|
QA completed on the combined stack branch and the work has been superseded by #35. What I validated:
Closing this PR in favor of the QAed combined branch. |
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.
Summary
NIGHT_SHIFT_*variables into setup, maintenance, provider execution, and verification flowsTesting
gleam test