chore: add guardrails for domain type operations and git history #340

Merged
jwilger-ai-bot merged 1 commit from chore/guardrail-domain-type-operations into main 2026-04-11 09:48:56 -07:00
jwilger-ai-bot commented 2026-04-11 09:43:12 -07:00 (Migrated from github.com)

Summary

Guardrail updates from PR #334 review feedback:

  • New rule: domain-type-operations.md — domain types expose operations via methods/trait impls, not inner value extraction. into_inner() only at IO boundaries.
  • New rule: no-rewrite-pushed-history.md — never amend/squash/rebase pushed commits unless explicitly asked.
  • Updated REVIEW.md — added domain type operation checks to invariants and "What to Block" list.
  • Updated blueprints/type-system.md — added "Domain Operations Over Inner Value Extraction" design principle.

Test plan

  • No code changes — rules, review criteria, and blueprint only
  • All hooks pass

Context

These guardrails were identified during review of PR #334 (nutype Into conversion). The reviewer flagged that extracting inner values for arithmetic defeats the purpose of domain types — callers should use domain operations instead.

## Summary Guardrail updates from PR #334 review feedback: - **New rule: `domain-type-operations.md`** — domain types expose operations via methods/trait impls, not inner value extraction. `into_inner()` only at IO boundaries. - **New rule: `no-rewrite-pushed-history.md`** — never amend/squash/rebase pushed commits unless explicitly asked. - **Updated `REVIEW.md`** — added domain type operation checks to invariants and "What to Block" list. - **Updated `blueprints/type-system.md`** — added "Domain Operations Over Inner Value Extraction" design principle. ## Test plan - [x] No code changes — rules, review criteria, and blueprint only - [x] All hooks pass ## Context These guardrails were identified during review of PR #334 (nutype Into conversion). The reviewer flagged that extracting inner values for arithmetic defeats the purpose of domain types — callers should use domain operations instead.
jwilger (Migrated from github.com) approved these changes 2026-04-11 09:45:19 -07:00
Sign in to join this conversation.
No description provided.