Review Before Shipping
1. Review Before Shipping
reporter.py is built and tested. Before shipping, one step remains: review. AI-generated code is fast but not always complete. This video uses the code-reviewer agent and a seven-item checklist to catch what tests miss.2. Why Review Matters
Passing tests don't mean production-ready code. AI-generated code can miss error handling, leave inputs unvalidated, or hardcode values that only work on one machine. These aren't bugs that break tests: they're issues that surface when real users run the tool in conditions you didn't anticipate.3. The 7-Item Checklist
Seven things to check in any AI-generated code. Secrets: no API keys or credentials hardcoded. Error handling: database down, bad file path. Edge cases: empty input, special characters. Input validation: does the CLI reject what it should? Test coverage: are the critical paths covered? Logging: can you trace a failure? Hallucinated imports: AI occasionally invents packages that don't exist.4. Using the Code-Reviewer Agent
Let's run through it on reporter.py. It returns five focused findings: SQL case-insensitivity, connection cleanup, NULL handling inconsistencies, a silent edge case, and lost error details. One follow-up prompt: "Fix the top issue." Claude adds COLLATE NOCASE to the SQL query. Artist search now works regardless of how the name is typed. One command, one real improvement.5. Development Lifecycle Complete
That's the full picture. Plan, build, test, review: each step made the next one easier. And together they form a workflow that applies to any project: APIs, pipelines, web apps. The same loop, every time.6. Let's Practice!
Plan, build, test, review: done. reporter.py is ready to ship. In the exercises, run the code-reviewer agent on the reporter and classify what you find. Critical issues get fixed. Everything else gets noted. Let's practice.Create Your Free Account
or
By continuing, you accept our Terms of Use, our Privacy Policy and that your data is stored in the USA.