aaronbrethorst/claude-skills/investigate-sentry
Claude Code and agent skill by aaronbrethorst/claude-skills
- community
Checking that the SKILL.md file is still in the repository.
Investigate and fix production errors from Sentry. Use when given a Sentry issue URL, numeric issue ID, or short ID (e.g. VOTERLETTERS-9R). Fetches full issue data via the Sentry MCP, analyzes root cause, scores fix confidence, and applies a TDD red-to-green fix in the Rails app. Triggers on "fix this Sentry issue", "investigate PROJ-XX", any sentry.io URL, or requests to debug a production error from Sentry.
Install
npx vskill@latest install aaronbrethorst/claude-skills/investigate-sentrySKILL.md
The same SKILL.md was published earlier as aaronbrethorst/claude-skills/investigate-sentry.
Sentry Issue Investigation & Fix
Fetch a Sentry issue, analyze root cause, score confidence, and fix via TDD.
Workflow
- Fetch — Subagent retrieves all Sentry issue data, writes to tempfile
- Analyze — Subagent scores the issue on three dimensions
- Decide — Branch on scores to plan-only, plan-then-fix, or auto-fix
- Fix — TDD red-to-green: write failing spec from Sentry data, then implement fix
Phase 1: Fetch Sentry Data
Launch a general-purpose subagent with this prompt structure:
The subagent returns the tempfile path.
Phase 2: Analyze and Score
Launch a general-purpose subagent. Include /rails-development skill invocation and use context7 MCP for Rails documentation. Pass the tempfile path from Phase 1.
Prompt structure:
Phase 3: Decision Tree
Parse the scores from the subagent response and branch:
Path A: User Review Required
Condition: Any score <= 30 OR combined < 150
The issue is too risky or uncertain for autonomous fixing. Enter plan mode and present the analysis to the user for evaluation. Include the full score breakdown, proposed fix, and why confidence is low or risk is high.
Path B: Auto-Fix
Condition: All three scores > 80
The issue is simple, well-understood, and safe. Proceed directly to Phase 4 (TDD Fix).
Path C: Plan Then Fix
Condition: All other cases (scores between 30-80, combined >= 150)
Enter plan mode to create a detailed fix plan covering:
- Exact spec to write (with code outline)
- Exact production code change
- Which existing specs to run for regression check
Then proceed to Phase 4 to implement.
Phase 4: TDD Fix (Red-to-Green)
Launch a general-purpose subagent with /rails-development skill and context7 MCP.
- Write the failing spec first. Use error data from Sentry (error class, message, request params, user context) to construct a spec that reproduces the exact failure. Use RSpec with FactoryBot (check the project — if it uses Minitest, use that instead).
- Run the spec — confirm it fails (RED). The spec MUST fail for the right reason (same error as Sentry). If it passes, the spec doesn't reproduce the issue — revise it.
- Implement the minimal fix. Fix the root cause, not symptoms. Follow rails-development skill conventions.
- Run the spec — confirm it passes (GREEN). The previously-failing spec now passes.
- Run the broader spec suite for affected files to catch regressions:
`` bundle exec rspec spec/models/[affected]_spec.rb spec/requests/[affected]_spec.rb ``
- Report results. Summarize what was fixed, the spec added, and test results.
Input Parsing
Accept any of these formats:
- Full URL:
https://sentry.io/organizations/org/issues/12345/orhttps://org.sentry.io/issues/PROJ-XX/ - Short ID:
VOTERLETTERS-9R,PROJ-123 - Numeric ID:
12345 - Natural language: "fix the sentry issue VOTERLETTERS-9R" (extract the ID)
Security
- Security scanPassed, 90 of 100Pattern checks on the skill's files.
- Model reviewPassed
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryCheckinginvestigate-sentry/SKILL.md
Popularity
- 7-day trend score
- 0
Not refreshed yet.
Works with
Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.
- Claude Code
- Cursor
- GitHub Copilot
- Windsurf
- Codex
- Gemini CLI
- Cline
- Amp
- Roo Code
- Goose
- Continue
- Kilo Code
- Junie
- Trae
- OpenHands
- Qwen Code
- AI Agent
- Tabnine Chat
- Sourcegraph Cody
- Amazon Q
- Firebase Genkit
- Sweep
- Devin
- Phind
- Mentat
- Claude Desktop
- Aider
- GPT Pilot
- Plandex
- bolt.new
- v0
- Replit Agent
- Anse
- TypingMind
- BetterChatGPT
- LibreChat
- Warp AI
- Pieces
- Fig AI
Embed badge
[](https://verified-skill.com/skills/aaronbrethorst/claude-skills/investigate-sentry)