From claude-dev-infrastructure
Guides debugging of AI-claimed fixes that fail in browser using Reality Check Matrix, binary search via git, and isolation in Vue.js/React apps with state issues.
How this skill is triggered — by the user, by Claude, or both
Slash command
/claude-dev-infrastructure:crisis-debugging-advisorThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
**Category**: Development Strategy & Debugging Methodology
Category: Development Strategy & Debugging Methodology Target Users: Developers feeling stuck with countless app issues and AI false success claims Primary Goal: Systematic approach to regain control when AI assistants claim success but reality shows broken functionality
Use this advisor when you experience:
Golden Rule: Manual verification ALWAYS trumps AI claims. If it doesn't work in browser, it's broken. Period.
This skill implements the Reality-First Verification Protocol (RFVP):
Objective: Establish ground truth of what actually works vs. what's broken
# Step 1: Create a Reality Check Matrix
# Create this file manually in your project root:
REALITY_CHECK.md
# Structure:
## Core Functionality Status
- [ ] App loads without console errors
- [ ] Basic task creation works
- [ ] Data persistence (IndexedDB) works
- [ ] Navigation between views works
- [ ] Timer functionality works
- [ ] Canvas interactions work
## AI Claim vs Reality Test
- [ ] AI: "Fixed X" → Manual Test: [ ] Actually works
- [ ] AI: "Implemented Y" → Manual Test: [ ] Actually works
Immediate Actions:
Objective: Systematically isolate the root cause using divide-and-conquer
Binary Search Protocol:
# Implementation Example:
git log --oneline -20 # List last 20 changes
# Test changes 1-10: npm run dev + manual test
# If broken: test changes 1-5
# If working: test changes 6-10
# Continue until single problematic commit identified
Vue.js Specific Binary Search:
Objective: Build from a working foundation, verifying each layer
Layer-by-Layer Verification:
// Layer 1: Core App Bootstrap
const coreAppTest = {
test: "Does Vue app mount without errors?",
verify: () => {
// Remove all components, just test app mounting
createApp(App).mount('#app')
}
}
// Layer 2: Basic State Management
const storeTest = {
test: "Does basic Pinia store work?",
verify: () => {
// Test simplest store with basic counter
const testStore = defineStore('test', () => {
const count = ref(0)
return { count }
})
}
}
// Layer 3: Basic Component
const componentTest = {
test: "Does simplest component render?",
verify: () => {
// Test component with just <div>Hello World</div>
}
}
Reconstruction Order:
Objective: Establish systematic AI verification workflow
AI Verification Protocol:
FOR EACH AI SUGGESTION:
1. AI provides code change
2. BEFORE implementing: Create success test criteria
3. Implement change
4. MANUAL verification in browser
5. IF works: Accept and document
6. IF fails: Reject and report back to AI with exact failure
Success Test Criteria Template:
// Before accepting AI suggestion:
const successCriteria = {
feature: "Task Creation",
steps: [
"Navigate to BoardView",
"Click 'Add Task' button",
"Type 'Test Task'",
"Press Enter",
"Task appears in list"
],
expectedResults: [
"No console errors",
"Task persists on refresh",
"Task appears in correct swimlane"
]
}
Create these in your project for systematic testing:
1. Core Functionality Test (test-core.js):
// Run in browser console to test basic functionality
const coreTests = {
testAppMount: () => {
return document.querySelector('#app') !== null
},
testNoConsoleErrors: () => {
// Monitor console for 30 seconds
return console.errorCount === 0
},
testBasicStore: () => {
// Test if Pinia stores are accessible
try {
const store = useTaskStore()
return store !== undefined
} catch {
return false
}
}
}
2. Store State Validator (validate-stores.js):
// Run to validate all store states
const validateStores = () => {
const stores = ['tasks', 'canvas', 'timer', 'ui']
const results = {}
stores.forEach(storeName => {
try {
const store = useStore(storeName)
results[storeName] = {
accessible: true,
hasData: Object.keys(store.$state).length > 0,
errors: null
}
} catch (error) {
results[storeName] = {
accessible: false,
hasData: false,
errors: error.message
}
}
})
return results
}
Browser DevTools Configuration:
Essential Browser Extensions:
Root Causes:
Debugging Steps:
Root Causes:
Debugging Steps:
Root Causes:
Debugging Steps:
Root Causes:
Debugging Steps:
When app is completely broken:
# 1. Create minimal working version
mkdir crisis-recovery
cd crisis-recovery
# 2. Copy only essential files
# - package.json
# - vite.config.js (minimal)
# - index.html (minimal)
# - src/main.ts (basic Vue setup)
# - src/App.vue (empty template)
# 3. Build incrementally
# Start with blank app, add one feature at a time
# Start binary search through git history
git bisect start
git bisect bad HEAD # Current version is broken
git bisect good v1.0-stable # Last known good version
# Git will checkout a commit for testing
npm run dev
# Test manually
git bisect good # or git bisect bad
# Continue until problem commit is identified
<!-- Create TestComponent.vue for isolation -->
<template>
<div class="test-component">
<h2>Component Test: {{ componentName }}</h2>
<button @click="testClick">Test Click</button>
<p>Clicks: {{ clickCount }}</p>
<p v-if="error" class="error">Error: {{ error }}</p>
</div>
</template>
<script setup>
import { ref } from 'vue'
const props = defineProps({
componentName: String
})
const clickCount = ref(0)
const error = ref(null)
const testClick = () => {
try {
clickCount.value++
// Add component-specific test logic here
} catch (e) {
error.value = e.message
}
}
</script>
Bad Report: "The app is broken" Good Report:
ISSUE REPORT:
- Feature: Task creation in BoardView
- Steps to Reproduce:
1. Navigate to BoardView
2. Click "Add Task" button
3. Type "Test Task"
4. Press Enter
- Expected Result: Task appears in "Planned" swimlane
- Actual Result: Button click does nothing, no console errors
- Browser Console: [Paste exact console output]
- Environment: Chrome 120, Vue 3.4.0, Pinia 2.1.0
Template:
CONTEXT: I'm in a crisis debugging situation. Previous AI suggestions claimed success but functionality is still broken.
CURRENT STATUS:
- Working: [List what actually works]
- Broken: [List what's broken with specific failures]
- Last Working Version: [git tag or description]
- Recent Changes: [List recent modifications]
REQUESTED ACTION:
- [Specific, measurable request]
- Success Criteria: [How I'll verify it works]
- Verification Plan: [How I'll test before accepting]
CONSTRAINTS:
- I will manually verify in browser before accepting
- I need incremental changes, not wholesale rewrites
- If you're uncertain, please say so rather than guessing
// Create automated smoke tests
const smokeTests = {
testBasicFunctionality: async () => {
// Test core app functionality
await page.goto('http://localhost:5546')
await expect(page.locator('#app')).toBeVisible()
await expect(page.locator('[data-testid="task-create"]')).toBeVisible()
},
testDataPersistence: async () => {
// Test that data saves and loads
await page.fill('[data-testid="task-input"]', 'Test Task')
await page.press('[data-testid="task-input"]', 'Enter')
await page.reload()
await expect(page.locator('text=Test Task')).toBeVisible()
}
}
When Everything Feels Broken:
Remember: Your manual testing is the ground truth. AI tools are assistants, not authorities. If it doesn't work in the browser, it's broken - regardless of what AI claims.
Created by: Crisis Debugging Research Team Based on: Systematic debugging methodologies, AI verification protocols, and real-world crisis recovery scenarios Last Updated: 2025-11-09
CRITICAL: Before claiming ANY issue, bug, or problem is "fixed", "resolved", "working", or "complete", the following verification protocol is MANDATORY:
REQUIRED: Use the AskUserQuestion tool to explicitly ask the user to verify the fix:
"I've implemented [description of fix]. Before I mark this as complete, please verify:
1. [Specific thing to check #1]
2. [Specific thing to check #2]
3. Does this fix the issue you were experiencing?
Please confirm the fix works as expected, or let me know what's still not working."
Remember: The user is the final authority on whether something is fixed. No exceptions.
npx claudepluginhub mulkerrin-sean/cc-marketplace --plugin claude-dev-infrastructureGuides debugging of AI-claimed fixes that fail in browser using Reality Check Matrix, binary search via git, and isolation in Vue.js/React apps with state issues.
Guides systematic root-cause debugging with a structured triage process. Use when tests fail, builds break, or behavior doesn't match expectations.
Guides systematic root-cause debugging with triage checklist for test failures, build breaks, runtime bugs, and unexpected errors. Covers reproduce, localize, fix, and guard steps.