T-9WPJ-resolve-searches-every-planning-root
State: planning/draft · Impact: high · Complexity: small
This repo nests sdlc projects: the root, plus solutions/determined with its own sdlc.yaml and
docs/planning/. From the repo root, sdlc task resolve T-K96T prints NO TASK FOUND for a
determined task, so every determined task needs its lease and branch handled by hand. This is the
narrow fix; T-G3EH-federated-planning-roots-union-loading-flat-resolution-union is the general
planning_roots mechanism and should absorb this lookup when it lands.
resolveTaskFile (lib/model/entities/task/ops/resolve.ts:120-126) uses an absolute path as
given and joins anything else under <projectRoot>/docs/planning/tasks. projectRoot comes from
resolveProjectRoot() (lib/config/load.ts:1648-1651), which walks up to the nearest sdlc.yaml.
A task in another root is invisible. A relative path to a task file
(solutions/determined/docs/planning/tasks/T-K96T-….md) is treated as a filename, so it also
fails from the repo root.
Proposed
Section titled “Proposed”Task lookup searches every planning root in the repository: the git root’s docs/planning/ plus
each nested directory holding an sdlc.yaml with a docs/planning/. An ID found in exactly one
root resolves; an ID found in more than one fails with both paths listed. A relative path that
names an existing file resolves as a path, from any directory.
Approach
Section titled “Approach”- Add a
planningRoots(gitRoot)helper that lists the root and every nestedsdlc.yamldirectory (skipnode_modules,.sdlc/worktrees, and other worktrees). - Make
resolveTaskFiletry a relative path as a file (against cwd) before the ID lookup. - Search every root for the ID; return an ambiguous result when more than one matches.
- Point the
task resolveop and its tests at the new lookup; keep the single-root result shape.
| Area | Note |
|---|---|
solutions/ontological/lib/model/entities/task/ops/resolve.ts | The lookup |
solutions/ontological/lib/config/load.ts | resolveProjectRoot; candidate home for root discovery |
Acceptance criteria
Section titled “Acceptance criteria”- AC-1: From the repo root,
sdlc task resolve T-K96Tfinds the determined task. - AC-2: An ID present in two roots fails and names both files.
- AC-3:
sdlc task resolve solutions/determined/docs/planning/tasks/T-K96T-….mdworks from the repo root. - AC-4: Tests cover root, nested root, ambiguous, and relative-path lookups.
Out of scope
Section titled “Out of scope”planning_rootsinsdlc.yaml, union loading, and qualified links (T-G3EH, D-SK9G).task start(T-55H8) and worktree placement (T-8CK0).