# Fix production bugs with a coding agent and a security check

Let a coding agent pick up an error from Sentry, write the fix and tests, and open a pull request that a security skill reviews before a person merges.

Fields: Software development, Security · Jobs: Fix bugs and ship small features; Audit code for vulnerabilities

## Steps

### 1. Read the error

The Sentry MCP gives the agent the stack trace and context.

Uses: [Sentry MCP and agent toolkit](https://aiteamguide.com/hub/mcp-servers/getsentry-toolkit/)

### 2. Fix with a plan

Use Superpowers so the agent plans and writes tests first, with current docs from Context7.

Uses: [Superpowers](https://aiteamguide.com/hub/skills/obra-superpowers/), [Context7](https://aiteamguide.com/hub/mcp-servers/upstash-context7/)

### 3. Open the PR

The GitHub MCP server opens the pull request.

Uses: [GitHub MCP Server](https://aiteamguide.com/hub/mcp-servers/github-github-mcp-server/)

### 4. Security review

Run Trail of Bits skills on the diff, and vet any new skill or MCP server with SkillSpector before installing it.

Uses: [Trail of Bits Skills](https://aiteamguide.com/hub/skills/trailofbits-skills/), [SkillSpector](https://aiteamguide.com/hub/skills/nvidia-skillspector/)

> Written by AITeamGuide from the tools' own docs. We haven't run it end to end in production; test with your own data first.

---
From the AITeamGuide Hub: https://aiteamguide.com/hub/playbooks/fix-production-bugs-safely/ (written by the AITeamGuide editors, 2026-10-21). Free to copy and adapt.
