Takedown: add the polish step to green-suite (ADR-0293, #1005 slice 2) #1009
Labels
No labels
P0
P1
P2
P3
bug
category/code-change
category/cross-repo
category/eval-run
category/investigation
category/no-test-target
category/owner-ruling
category/prose-artifact
category/recurring-chore
category/structure
category/umbrella
crc-refactor
create
delete
enhancement
filed-by/agent
filed-by/user
frozen
lint-rule
needs-info
needs-triage
next
plugin/cc-architect
plugin/os
plugin/os-adr
plugin/os-aidd-lint
plugin/os-backlog
plugin/os-context
plugin/os-doc-hygiene
plugin/os-sdlc
plugin/os-vault
project/cc-os
ready-for-agent
ready-for-human
recurring
review
rule-proposal
update
waiting
wayfinder:grilling
wayfinder:map
wayfinder:map
wayfinder:research
wayfinder:task
wayfinder:task
wontfix
worklist/deviations
worklist/lint-rule
worklist/new-implement-build
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
jared/cc-os#1009
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?
Problem
After #1005 (slice 1), a live takedown run that has green suites and new lint offenses fails at
green-suite. ADR-0293 requires apolishstep that repairs the form of the design before it becomes final. Without this step, no live design with offenses can become final, and the D2 tracer stays blocked.This ticket is slice 2 of #1005. The split happened on 2026-10-15, because the blast-radius report showed that one run (about 12 lib files and 5 test files) is too large.
Reproduce
n/a: feature ticket; the step does not exist yet.
Approach
Required work: none beyond the acceptance criteria.
Behavior is fixed by ADR-0293. The design is open. Known parts from the blast-radius report: a new
StepProfileentry forpolish,harness/cards/polisher.md,harness/schemas/polish.json, apolishbranch inStepList#build, and a loop inFlowaroundgreen-suite.OsSdlc::Lesson::Relay(lib/os_sdlc/presenter/lesson/relay.rb:4, takeslibrary:andseen_keys:) supplies lessons;adapter/gate_red.rb:12is the existing example of an eval-to-OsSdlc reference.Pinning tests that change (under
plugins/os-sdlc/eval/ticket-takedown/):test/model/harness_files_test.rb(line 16, the card set; line 156, the schema set),test/command/pipeline_test.rb(line 442 and line 258, thefinal-design.jsonkey set). Writepolish_roundsin live mode only, so that the eval-mode key set stays the same.Also inject
LintRunfrom the entry point (lens P2 challenge, implementation 45: code defect). Todaymodel/suite_check.rb:5haslint: LintRun.newas a default, andadapter/lint_run.rb:7defaultsrunner: ProcessRunner.new, so production lint does not useenv.runner. FollowSuiteRunner: buildLintRun.new(runner: runner)incontroller/run_cli.rbnext tosuites:(line 49), carry it throughCollaborators,StepListandGreenSuiteSteptoSuiteCheck.run, and remove both defaults. Update the green-suiteStepList.newcalls intest/command/green_suite_test.rb,test/command/final_suite_test.rb(line 197) andtest/command/pipeline_test.rb.Implementation route:
/os-sdlc:implement <this ticket> poodr-ticket-implementation, nottakedown-implement. The pipeline cannot polish its own fix (bootstrap).Acceptance criteria
lint_configthat is not present at base, whengreen-suiteruns, then the next step ispolish, andgreen-suiteruns again after it.polishruns, then its input is the offenses and the lint lesson fromplugins/os-sdlc/lint-lessons/(read throughLesson::Relay) when one exists for the cop. It never receives the ruling or the grade. It changes form only.polishreturns files, when the guard runs, then the target suites pass and the design's failing tests are still red at base. If either check fails, the polish round does not count as a success.final-design.jsonholds the polished files,source_stepnames the graded design, and a newpolish_roundsfield holds the polish count.place-design, the implement body and thetakedown-implementmap keep readingfinal-design.json.polishdoes not run and thefinal-design.jsonkey set is unchanged.Owner sketch
Non-goals
green-suiterename, the lint baseline, and the test-red return torevise: #1005.docs/handoffs/2026-10-15-lint-lesson-analysis.md).Blocked by #1005. Blocks the D2 tracer.
Origin
polishstep ←DESIGN: ADR-0293 decisions 3 and 4Work started 2026-10-15 (session fb136c57) on branch prism-architect. Route: /os-sdlc:implement 1009 poodr-ticket-implementation. #1005 (slice 1) closed and merged.
Skeptic DROP (lens follow-up): depth-1 rule; no observed failure yet. Lens challenge found two code defects (signals
b89d0233A12,edda0d5dP2): (1) presenter/prompts.rb:5 builds LintLessons.for as a default; test/command/polish_test.rb:154 asserts real lesson text, so a lesson edit breaks the test. (2) command/flow.rb:29 suite_tests_green? copies SuiteCheck#tests_green?; fix is a tests_green key in SuiteCheck#to_h. File a ticket if the polish test breaks on a lesson edit.Resolution
Done: ADR-0293 polish loop built via poodr-ticket-implementation (implementation 46, 20 dispatches, 26 min): lint-red green-suite goes to a polish model step (offenses + lessons via OsSdlc Lesson::Relay, no ruling or grade); guard after polish (suites pass, failing tests red at base); limit 5 rounds or stall, then escalate; grade stays on the unpolished design; final-design.json holds polished files and polish_rounds (live only); LintRun injected from run_cli.rb (P2 fix from #1005).
Evidence: Commit
eb77efcfon prism-architect (runner commit; suite-check green; behavior-verifier pass on round 3; contract-auditor pass). Recordsd439af13(README polish row, os-sdlc leaf History row). Lens signalsb89d0233(A12),edda0d5d(P2) on main.Follow-ups: Lens A12 and P2 code defects: skeptic DROP, recorded in the comment above. No other follow-ups.