Repository navigation
Conversation
Domain modules (ADRs 0006, 0007, 0009, 0010), routes (0004, 0005), and web rules (0001, 0002, 0005, 0008), each citing its ADR so code review can enforce it. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Each rule now applies to new or changed code, keeps its ADR's strength, scope and exemptions, and names the paths still migrating. Adds the missing rules from ADRs 0001, 0004, 0005, 0006 and 0008. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
…ules to their ADRs and name the code that predates them. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds the coding rules taken from the ADRs to
CODING_STANDARDS.md. They were split out of #91 so each one can be reviewed beforecode-reviewstarts enforcing it.Scoping decisions
A rule
code-reviewenforces must hold for the code at head, or be scoped to new or changed code with the known exceptions named. Where a rule is scoped, it says so and lists what predates it:createContainerForSpecimenuntil their slice lands (POST /specimens,POST /specimens/:id/containers, derivations and the derivation CSV, control batches), and the ADR's exception: a caller whose own writes come first wraps the whole write inwithRolledBackTransaction.getValue,get(key).value,putValue,update, and the bulk*ConfigurationsApi.updatewrappers.error_logs, never the other way) and the ADR's exception for bootstrap, migration and script prose. Two request-timeconsoleuses predate the rule:logTemplateErrorinqpcr-experiments.tsand the seeding lines inPOST /setup/initialize..optional()(0005): container wire schemas from@sampledb/contract/wireonly, for fields added from now on. The existing.nullable().optional()fields incontainer-wire.tsand other parsers are out of scope.ContainerMovePapers.tsxandCollectionMove.tsxare out of scope.Evidence
git grep: every named symbol and file exists, and every rule either holds at head or names the code that breaks it. The first draft said it found no violations; that was wrong (unmigrated registration callers, request-timeconsolecalls, direct mutations, row spreads,.nullable().optional()wire fields), and those are now listed in the rules.Merge Danger
Door: two-way
Blast Radius: code-review
Every rule here becomes something
code-reviewflags. A rule that is too strict will produce noisy findings until it is removed.🤖 Generated with Claude Code