diff --git a/CLAUDE.md b/CLAUDE.md index 0b12f1652..acd32bb7d 100644 --- a/CLAUDE.md +++ b/CLAUDE.md @@ -57,10 +57,15 @@ See [docs/DEVOPS.md](docs/DEVOPS.md) for build, test, lint, and CI procedures. A 3. Read the relevant `decisions/*.md` domain file(s) referenced in the briefing 4. Background context: `docs/briefings/{your-name}.md`, `docs/discussions/` -### SQLite access -**Never use the `sqlite3` CLI** - it crashes in Claude Code due to a known std::bad_alloc bug. +### Ticket and database access +**Prefer the ticket CLI over raw SQL.** The CLI handles column names, joins, and output formatting correctly: +```bash +db/connectors/ticket list --sprint 2 --team server +db/connectors/ticket show 78 +db/connectors/ticket sprint --active +``` -Use the whitelistable wrapper scripts: +Only fall back to raw SQL for queries the CLI doesn't support. **Never use the `sqlite3` CLI** — it crashes in Claude Code due to a known std::bad_alloc bug. Use the wrapper scripts instead: ```bash db/connectors/sqlite-query "SELECT * FROM tickets WHERE status='in_progress'" db/connectors/sqlite-exec "UPDATE tickets SET status='done' WHERE id=1"