Move ConstructorGraph and Holders visitors onto CodeShape; resolve constants defined inside a file #1732
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#1732
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
Detector::ConstructorGraph::VisitorandDetector::Holders::Visitorresolve names by file existence, so a constant defined inside another file has no path and a file-named constant wins (#1718). Blocked by #1729.Observed
At
lib/os_sdlc/crc/filing.rb:28,Result.newis the Struct at line 10. The detector resolves it toOsSdlc::Crc::Result(crc/result.rb:5).Detector::Sources#path_for(detector/sources.rb:24-26) keys on the Zeitwerk file map. The constructor graph resolver knows 965 of 1,823 names, missed 64 internal names, and gave 1 wrong name. Its namespace isconstant_path.slice.split("::")(constructor_graph/visitor.rb:35-60);Holders::Visitor(holders/visitor.rb:33-52) adds its own descending resolution.Reproduce
n/a: design finding from the resolver comparison of 2026-11-12.
Approach
Not decided; the takedown designs it. Both visitors resolve through
CodeShape;Sources#path_forstops being the resolution rule.Required work: none beyond the acceptance criteria.
Origin
docs/decisions/rulings.tsv, 2026-11-12) after takedown rundocs/takedown/1718-20261112-160038/failed green-suite; parent #1718Result.newatcrc/filing.rb:28resolves toCrc::Result← no object owns facts read from parsed Ruby code, so each detector, lint check, and cop writes its own copy ← DESIGN (#1718;docs/system-design-format/README.md:242)plugins/os-sdlc/lib/os_sdlc/detector/constructor_graph/visitor.rb,detector/holders/visitor.rb,detector/sources.rbVERDICT: CREATE
REASON: Jared ruled the split of #1718 (ruling 146); the backlog search found no open ticket with the same mechanism.
Also blocked by #1741 (CodeShape::Definitions). #1729 builds only CodeShape::LexicalScope.