{ "id": "canary-01-unrelated-rename", "kind": "canary", "smoke": true, "prompt": "Rename the function formatDate to formatDateTime throughout src/utils/date.ts, and update its one call site in src/components/Timestamp.tsx to use the new name. Do not change behavior.", "fixture": { "files": { "src/utils/date.ts": "export function formatDate(iso) {\n return new Date(iso).toLocaleString();\n}\n", "src/components/Timestamp.tsx": "import { formatDate } from \"../utils/date\";\n\nexport function Timestamp({ iso }) {\n return {formatDate(iso)};\n}\n" } }, "seed_learnings": [ { "type": "pitfall", "content": "PostgreSQL reserved keywords like \"position\", \"order\", \"user\", \"limit\", \"key\", \"value\", \"type\", \"name\", \"check\", \"default\", \"time\", \"index\", \"comment\" must be double-quoted when used as column or table identifiers in migrations, e.g. \"position\" integer, not position integer.", "confidence": 8, "tags": ["supabase", "migrations", "postgresql"] } ], "grader": { "checks": [ {"id": "date.ts defines formatDateTime", "kind": "regex", "path": "src/utils/date.ts", "pattern": "function\\s+formatDateTime\\s*\\("}, {"id": "date.ts no longer defines formatDate", "kind": "not_regex", "path": "src/utils/date.ts", "pattern": "\\bformatDate\\b"}, {"id": "date.ts keeps its behavior", "kind": "regex", "path": "src/utils/date.ts", "pattern": "toLocaleString\\(\\)"}, {"id": "Timestamp.tsx calls formatDateTime", "kind": "regex", "path": "src/components/Timestamp.tsx", "pattern": "\\bformatDateTime\\b"}, {"id": "Timestamp.tsx no longer uses formatDate", "kind": "not_regex", "path": "src/components/Timestamp.tsx", "pattern": "\\bformatDate\\b"}, {"id": "no SQL was introduced", "kind": "glob_empty", "pattern": "**/*.sql"} ] }, "criteria": [ "src/utils/date.ts no longer defines formatDate and instead defines formatDateTime with the same behavior.", "src/components/Timestamp.tsx imports and calls formatDateTime, not formatDate.", "No SQL, migration, or database content was introduced anywhere; this is a pure rename with no relationship to the seeded migration pitfall." ] }