Configure milestone outcome prompts - #60
Conversation
|
Multiple outcome-enabled milestones corrupt “final outcome” semantics The feature is supposed to work on arbitrary milestones, and the store explicitly permits more than one milestone to carry the outcome flag. Trainer History, however, aggregates every completion and attempt from every currently flagged milestone into one bar, while telling the user it represents each dog’s most recent final decision. A dog with an outcome on Grounds and another on Advanced Final Blindfold is therefore counted twice. The release behavior has the same hidden assumption. Any Fail releases the dog, but clearing one milestone’s previous Fail automatically reactivates the dog without checking whether another outcome-enabled milestone still has a current Fail. This needs an architectural distinction: Generic outcome prompt: allowed on any milestone. At present, the interface says “outcome prompt,” but the data model still treats every enabled prompt as the terminal evaluation. |
|
Turning Repeatable off hides the preserved attempt history The ledger is not deleted, but it becomes inaccessible: A currently repeatable outcome milestone displays its attempts. That contradicts the PR’s preservation guarantee. Changing future behavior should not make past attempts vanish from the dog profile. Fix: render historical attempts whenever ledger rows exist, independent of the milestone’s current prompt/repeatable configuration. The current flag should control future recording behavior, not historical visibility. |
|
CI is green across tests, lint, build, and Worker type-checking. But the new tests cover canonicalization and pure permission checks, not multi-milestone statistics, release interactions, or configuration transitions around existing attempts. The underlying allowed-outcome implementation is good. These are boundary failures produced by attaching a general feature to machinery that still assumes one terminal outcome milestone. |
|
Addressed all requested changes in dd44aad:
|
Summary
User impact
Milestones can now match the real evaluation workflow without erasing prior dog records when the curriculum changes. Repeatable attempts remain visible even if the prompt is later disabled.
Validation
npm test(14/14)npm run buildnpx tsc -bnpm run lint(only three pre-existing warnings)npm --prefix worker run typecheckgit diff --checkCloses #33