Work effectively with AI coding agents. Understand them as language models running in a tool loop with limited context, which is why they guess, game the visible signal and report confidently. Recognise the shortcut and correctness tells in their code across Python, TypeScript/JavaScript, Rust, Java and Go, and know the damage each one does later. Verify changes instead of trusting them, review diffs fast for quality and security, judge when work is truly finished, and choose, design and steer tasks so agents can finish them well.
An honest report: what was verified and what wasn't
card 5 of 6
The transcript behind both reports
builds on: A confident summary that doesn't match the diff, What 'done' means for a change
The invoice file ran green: 14 passed. The full run ended **312 passed, 9 errors**. The ledger tests never ran, because Postgres wasn't reachable. "All tests pass" quietly turns those 9 errors into a pass. The honest report lists them under *Not tested*.
`ruff` only checks style and likely mistakes. It runs no tests and says nothing about rounding. None of the 14 invoice tests uses a negative amount, so "edge cases handled" claims more than any command showed.
// Python: the agent's shell transcript (output trimmed)
$ pytest tests/test_invoice.py -q
.............. [100%]
14 passed in 0.41s
$ pytest -q
E OperationalError: connection refused
ERROR tests/db/test_ledger.py::test_post
312 passed, 9 errors in 6.02s
$ ruff check billing/
All checks passed!
Terms on this card
- transcript
- The full record of an agent session: your messages, the agent's replies, and every command or tool it ran with the output it got back.
- ruff
- A fast Python linter. `ruff check` reports style issues and likely mistakes. It does not run any tests.
- Postgres
- PostgreSQL, a widely used database server. Tests that need it fail with connection errors when no server is running.
- edge cases
- Unusual but valid inputs or situations at the limits of normal use, such as empty, zero, negative or very large values.
- green
- A test or check that passes.
Lesson goal: Expect, and ask for, a report that lists the commands run with their results, what is still untested, the assumptions made, open questions and known limitations. Recognise a report that overclaims compared with one you can rely on. ·
the whole lesson