Bundle WorktreeCreationService I/O collaborators so createWithLock forwards without restatement #442
Labels
No labels
agent-ready
bug
contract
documentation
duplicate
enhancement
good first issue
help wanted
invalid
needs-human
needs-input
question
wontfix
No milestone
No project
No assignees
2 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
iterative-works/iw-cli#442
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
dashboard/jvm/src/application/WorktreeCreationService.scala:48-61and:158-171.createandcreateWithLocktake the identical nine parameters, and the ~35-line@paramblock is copied verbatim onto both.createWithLockuses none of them — it acquires a lock, forwards every argument unchanged tocreate, and releases.Adding IW-423's
attachHintparameter therefore meant editing two signatures and two docstrings to say the same thing, and every test call site supplies the same bag twice.Lesson: a pass-through wrapper that restates its callee's whole parameter list makes every later parameter addition a two-site edit, and the duplication grows with each one.
Fix
Bundle the I/O collaborators into one record so
createWithLockforwards it without restatement.Not done in IW-423 because bundling is a design change to signatures that phase had just settled, and folding a refactoring into the de-tmuxing sweep would have made the sweep unreviewable.
Recorded during IW-423; see
project-management/issues/IW-423/LESSONS.mdentry 18.Intake: needs-input
Workflow: waterfall
Reason: G1 (1 CLARIFY marker)
Analysis: project-management/issues/IW-442/analysis.md on branch IW-442
1. Should IW-442 build the collaborator bundle now, or close as superseded by IW-477? (G1)
IW-442 asks for one record that holds the I/O collaborators of the dashboard's worktree-creation service. With it,
createWithLockwould forward one value and stop repeating the nine parameters ofcreate(analysis). IW-477 is open and waits for a human decision. Its plan makes the same service a thin adapter and rewrites its tests, so this record would be deleted (IW-477 analysis):Recommended: b): IW-477 removes the whole repeated parameter list, so this record would have no value after IW-477 lands.
Answer in a comment on this issue, per number, for example "1: a", or in your own words; intake reads it on its next iteration.