Discovery: replace source-root length ordering with explicit specificity policy #38
Labels
No labels
area:ci
area:docs
area:engineering
area:framework-fp
area:test-coverage
dogfood:fn
dogfood:fp
dogfood:friction
dogfood:tp
phase:b
phase:c
severity:critical
severity:high
severity:low
severity:medium
source:deepseek-v4-pro
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
pdurlej/fallow-py#38
Loading…
Add table
Add a link
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?
Source
Triaged from DeepSeek v4 Pro audit via #35.
Problem
discover_source_roots()currently uses string length ordering for inferred candidates. That happens to prefer child paths such assrc/over the repository root in common layouts, but the policy is implicit and brittle. The audit's exact example was overstated, but the implementation is still too clever-by-accident for a codebase-intelligence tool.Target behavior
Source-root ordering should be explicit and testable:
config.rootspreserve user intent after normalization/filteringnamespace_packagesAcceptance criteria
rootsto ensure user order/intent is not unexpectedly rewritten.len(p.as_posix())ordering with a named helper or clearly documented key.Out of scope
codex referenced this issue2026-05-12 08:37:36 +02:00