Sdlc/Sequel/DatasetResultCompared: carve out non-row terminals and non-Sequel _dataset names #1350
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#1350
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
The cop
Sdlc/Sequel/DatasetResultComparedflags a chain rooted at any*_datasetsend that is compared or tested.The matcher has no check for the root type, the terminal method, or the file location.
It flags code that is not a row decision.
Found by the #1325 zero-false-positive audit (docs/plans/class-length-family/sdlc-cop-audit.md).
Observed
Counterexample 1: a SQL-string check is not a row decision.
Counterexample 2: a non-Sequel method named
training_datasetis flagged.The lesson says "outside the owning model", but the matcher has no location check. The cop has 0 hits in plugins/.
Reproduce
n/a: matcher is
plugins/os-sdlc/lib/os_sdlc/cops/dataset_result_compared.rb:15-25; run the cop on the samples above.Approach
Carve-outs go in the cop matcher, never in a config Exclude list or a test-path exclusion.
Skip chains that end in
sql,columns, orsql_literal.Require the root to be an association dataset or
Model.datasetknown from the file, or skip when the file has no Sequel model.Required work:
sql_literalinplugins/os-sdlc/lib/os_sdlc/cops/dataset_result_compared.rbAcceptance criteria
orders_dataset.sql == expected, when the cop runs, then it reports no offense.training_dataset.size > 0, when the cop runs, then it reports no offense.orders_dataset.all == otherin a Sequel model, when the cop runs, then it still reports an offense.Origin
VERDICT: CREATE