Repository navigation
A repository's requires apply to every one of its tasks - #322
Merged
Merged
Conversation
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.
Objective
A repository now carries
requires, which every one of its tasks adds to its card's for placement and for the heavy-session flag.engine repo add --requiressets it, and operator-onlyengine repo edit <id> --version <n> --requires <caps>replaces it without touching the repo's identity. This keeps BOGA3's tasks off devbox, which has no iOS simulator, whatever capabilities a planner puts on a card. Planners are excluded because they run no gates.Gates
./dev test(every required lane)internal/control/repo_test.go: a repo edit replaces onlyrequires. It needs the current version (409), refuses any other field (400) and is operator-only (403). The union lists the repo's caps, then the card's, each once.internal/controlrun/placement_test.go: a repo requirement keeps a task off a host without that capability, then places it and makes it heavy once the host has it. A mutation check showed both halves fail without the change.internal/controlrun/coordinator_test.go: a planner for a repo with a heavy requirement is not heavy. This also failed under a mutation check.internal/controlcmd/command_test.go: the CLI runsrepo add --requiresandrepo edit --requires.Rulings
None
Review
spawn.gocomment, "replaces" in the usage line.engine task moverecovers it. Bumping every task's version on a repo edit costs more than it saves.control-server.mdtoo:hosts-and-sessions.mdowns it (one place per fact), and control-server is at its budget.operator(a)before the version check:workerItemalready returns 403 first, so the order exposes nothing.internal/controlrun/dispatch.go(the heavy flag uses the union for tasks only) andinternal/control/repo.go(what a repo edit accepts).Deviations
None
🤖 Generated with Claude Code