Skip to content

Debugging

Debugging

Guide to debugging the AI Arena platform.

Backend Debugging

Enable Debug Logging

Set environment variable:

DEBUG=*

Check Logs

Terminal window
# Backend logs
cd backend
pnpm run dev
# Check console output

Frontend Debugging

Browser DevTools

  1. Open browser DevTools (F12)
  2. Check Console for errors
  3. Check Network tab for API calls
  4. Check Application tab for storage

React DevTools

Install React DevTools browser extension for component debugging.

Database Debugging

Check Database File

Terminal window
cat backend/data/arena.json

Reset Database

Terminal window
rm backend/data/arena.json
pnpm run seed

API Debugging

Test Endpoints

Terminal window
# Health check
curl http://localhost:3001/health
# List agents
curl http://localhost:3001/api/agents

WebSocket Testing

Use WebSocket client tools or browser console.

Next Steps