Claude-skill-registry indexeddb-backup-debugger
Debug IndexedDB backup synchronization issues in Vue.js/Pinia applications by analyzing database state, tracing data flow, and identifying sync problems between UI, store, and backup systems.
git clone https://github.com/majiayu000/claude-skill-registry
T=$(mktemp -d) && git clone --depth=1 https://github.com/majiayu000/claude-skill-registry "$T" && mkdir -p ~/.claude/skills && cp -r "$T/skills/data/indexeddb-backup-debugger" ~/.claude/skills/majiayu000-claude-skill-registry-indexeddb-backup-debugger-684164 && rm -rf "$T"
skills/data/indexeddb-backup-debugger/SKILL.mdIndexedDB Backup Debugger
Debug IndexedDB backup synchronization issues in Vue.js/Pinia applications by systematically analyzing database state, tracing data flow, and identifying synchronization problems between UI components, Pinia stores, IndexedDB, and backup systems.
When to Use This Skill
Use this skill when:
- Backup system reports different task counts than actual UI data
- IndexedDB data appears stale or out of sync with Pinia store
- Backup system is not capturing current user data
- Data consistency issues between application layers
- Hebrew/Unicode content not properly preserved through backup cycles
- Real-time data synchronization problems in Vue.js applications
Core Debugging Workflows
Workflow 1: Database State Analysis
Execute database analysis to identify state inconsistencies:
- Run
to dump all IndexedDB databasesscripts/analyze-database.js - Compare task counts across Pinia store, IndexedDB, and backup system
- Identify which database version contains stale data
- Verify Hebrew content preservation across all storage layers
The analysis reveals:
- Multiple IndexedDB database versions (flow-state v1, v2, v3)
- Data inconsistencies between storage layers
- Stale data sources being read by backup system
- Unicode handling issues in backup/restore cycles
Workflow 2: Real-time Sync Monitoring
Monitor data flow and synchronization timing:
- Use
for real-time monitoringassets/debug-templates/sync-monitor.html - Track Pinia store mutations vs IndexedDB writes
- Verify backup system reads current data, not cached state
- Detect async timing issues and race conditions
Monitor for:
- Pinia store changes not persisting to IndexedDB
- Backup system reading from stale data sources
- Async timing conflicts between store updates and backup creation
- Data races in multi-tab scenarios
Workflow 3: Data Consistency Verification
Systematic verification of data integrity:
- Execute
to trace data pathscripts/trace-data-flow.js - Compare UI → Pinia → IndexedDB → Backup pipeline
- Test Hebrew content preservation through entire flow
- Verify backup/restore cycles with actual user data
Verify consistency across:
- UI task count vs Pinia store count
- Pinia store count vs IndexedDB count
- IndexedDB count vs backup system count
- Hebrew Unicode integrity through all layers
Key Debugging Tools
Database Analysis Script
scripts/analyze-database.js provides comprehensive database inspection:
# Analyze all IndexedDB databases and versions node scripts/analyze-database.js # Output includes: # - Database versions and schemas # - Task counts per database # - Data consistency checks # - Hebrew content verification
Data Flow Tracer
scripts/trace-data-flow.js tracks data movement:
# Trace complete data flow pipeline node scripts/trace-data-flow.js # Identifies: # - Data synchronization breaks # - Stale data sources # - Async timing issues # - Unicode handling problems
Real-time Monitor
assets/debug-templates/sync-monitor.html provides live monitoring:
- Real-time Pinia store observation
- IndexedDB change tracking
- Backup system data source verification
- Live synchronization status display
Common Issues and Solutions
Issue: Backup System Reading Stale Data
Problem: Backup system reports old task counts (e.g., 22 tasks) while UI shows current data (e.g., 4 tasks)
Debug Steps:
- Run database analysis to identify multiple database versions
- Check which version backup system is reading from
- Verify Pinia store ↔ IndexedDB synchronization
- Test manual backup creation timing
Solution: Ensure backup system reads from latest IndexedDB version and waits for Pinia → IndexedDB sync completion.
Issue: Hebrew Content Loss
Problem: Hebrew characters corrupted or lost during backup/restore
Debug Steps:
- Test Unicode preservation through JSON serialization
- Verify IndexedDB stores UTF-8 correctly
- Check backup system string handling
- Test restore process with actual Hebrew content
Solution: Implement proper Unicode handling and verify UTF-8 encoding throughout pipeline.
Issue: Async Timing Conflicts
Problem: Pinia store updates not reflected in backups due to timing
Debug Steps:
- Monitor Pinia store mutation timing
- Track IndexedDB write completion
- Verify backup system waits for data persistence
- Test rapid state changes
Solution: Implement proper async coordination between Pinia updates, IndexedDB writes, and backup creation.
Implementation Guidelines
Database Analysis Script Requirements:
- Support multiple IndexedDB database versions
- Compare task counts across storage layers
- Verify Hebrew Unicode content preservation
- Identify data source inconsistencies
Data Flow Tracing Requirements:
- Track UI → Pinia → IndexedDB → Backup pipeline
- Detect synchronization breakpoints
- Monitor async operation timing
- Verify Unicode handling at each stage
Real-time Monitoring Requirements:
- Live Pinia store observation
- IndexedDB change detection
- Backup system data source verification
- Visual sync status indicators
Expected Outcomes
Using this skill will identify:
- Exact point where backup data diverges from actual user data
- Which IndexedDB database version contains current vs stale data
- Pinia store synchronization timing issues
- Hebrew content preservation problems in backup pipeline
- Root cause of data consistency issues between application layers
The systematic approach provided by this skill enables precise diagnosis and resolution of IndexedDB backup synchronization problems in Vue.js applications.
MANDATORY USER VERIFICATION REQUIREMENT
Policy: No Fix Claims Without User Confirmation
CRITICAL: Before claiming ANY issue, bug, or problem is "fixed", "resolved", "working", or "complete", the following verification protocol is MANDATORY:
Step 1: Technical Verification
- Run all relevant tests (build, type-check, unit tests)
- Verify no console errors
- Take screenshots/evidence of the fix
Step 2: User Verification Request
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."
Step 3: Wait for User Confirmation
- DO NOT proceed with claims of success until user responds
- DO NOT mark tasks as "completed" without user confirmation
- DO NOT use phrases like "fixed", "resolved", "working" without user verification
Step 4: Handle User Feedback
- If user confirms: Document the fix and mark as complete
- If user reports issues: Continue debugging, repeat verification cycle
Prohibited Actions (Without User Verification)
- Claiming a bug is "fixed"
- Stating functionality is "working"
- Marking issues as "resolved"
- Declaring features as "complete"
- Any success claims about fixes
Required Evidence Before User Verification Request
- Technical tests passing
- Visual confirmation via Playwright/screenshots
- Specific test scenarios executed
- Clear description of what was changed
Remember: The user is the final authority on whether something is fixed. No exceptions.