Common Mistakes Tracker
Purpose
Maintain a living log of mistakes per project and technology stack. Every time Claude falls into a technical trap, the mistake gets recorded here so it never repeats.
This follows Anthropic's internal practice of maintaining a "common mistakes zone" that the model reads before starting work.
How It Works
Recording a Mistake
When a mistake is identified (by user correction, failed test, or explicit request):
- Identify the project name or technology
- Read the existing mistakes log:
mistakes-log.jsonin this directory - Add the new entry with:
category: The tech/framework/language involvedmistake: What went wrong (concise)correct_approach: What should have been donecontext: When this typically happensdate: When it was recorded
- Write the updated log back
Using the Mistakes Log
At the START of any coding task:
- Read
mistakes-log.json - Filter for entries matching the current technology/framework
- Keep these in mind as active constraints while coding
- If about to do something that matches a recorded mistake - STOP and use the correct approach instead
Mistakes Log Format
The file mistakes-log.json in this directory stores all entries as:
[
{
"id": 1,
"category": "react",
"mistake": "Used useEffect for derived state instead of useMemo",
"correct_approach": "Use useMemo for values computed from props/state, useEffect only for side effects",
"context": "When computing filtered/sorted lists from state",
"date": "2026-03-22",
"project": "my-app"
}
]
Key Principles
- Be SPECIFIC. Not "don't write bad code" but "don't use
anytype in TypeScript interfaces for API responses" - Include the CONTEXT - when does this mistake typically happen?
- The correct approach should be copy-paste ready when possible
- Review and prune outdated entries when frameworks/projects change
- Cross-project mistakes (like git habits) use category "general"
Categories to Watch
- Language-specific pitfalls (JS, Python, TypeScript quirks)
- Framework misuse (React, Next.js, Vue patterns done wrong)
- Architecture mistakes (wrong file structure, circular deps)
- Build/deploy errors (wrong configs, missing env vars)
- Hebrew/RTL specific issues (bidi text, font problems)
- Git workflow errors (wrong branch, force push accidents)