Troubleshooting Guide
Common issues and solutions for Agentification Academy.
Installation & Setup​
npm install fails​
Error: npm ERR! code ERESOLVE or dependency conflicts
Solutions:
# Clear cache and reinstall
rm -rf node_modules package-lock.json
npm cache clean --force
npm install
# Or use legacy peer deps (if above fails)
npm install --legacy-peer-deps
Python dependencies fail​
Error: ModuleNotFoundError or pip install errors
Solutions:
# Create fresh virtual environment
python -m venv venv
source venv/bin/activate # On Windows: venv\Scripts\activate
# Install requirements
pip install -r requirements.txt
# Update pip
pip install --upgrade pip
Development Server​
Port already in use​
Error: EADDRINUSE: address already in use :::5173
Solutions:
# Use different port
npm run dev -- --port 5174
# Or kill process on port
lsof -ti:5173 | xargs kill -9 # macOS/Linux
netstat -ano | findstr :5173 # Windows
Vite not finding modules​
Error: Failed to resolve module specifier or Cannot find module
Solutions:
- Check import paths are correct (relative vs absolute)
- Restart dev server:
Ctrl+C, thennpm run dev - Clear Vite cache:
rm -rf .vite
Build fails with "Could not resolve"​
Error: RollupError: Could not resolve "path/to/file"
Solutions:
- Verify file paths in imports match actual files
- Check for relative path issues after refactoring
- Look for typos in import statements
Database Issues​
Cannot connect to Supabase​
Error: FetchError: fetch failed or connection timeout
Solutions:
- Verify
VITE_SUPABASE_URLis correct - Check internet connection
- Verify Supabase project is running (check dashboard)
- Check if your IP is whitelisted
Database migrations failed​
Error: Migration files not applied or schema mismatch
Solutions:
# Check migration status
supabase migration list
# Manually apply schema
psql -h db.host -U postgres -d dbname -f supabase/schema.sql
# Check migrations folder
ls supabase/migrations/
Row-level security (RLS) blocking queries​
Error: new row violates row-level security policy
Solutions:
- Verify user is authenticated
- Check RLS policies in Supabase dashboard
- Ensure user has required role/permissions
- Check policy conditions (e.g.,
auth.uid())
Authentication Issues​
User cannot login​
Error: Invalid login credentials or blank login page
Solutions:
- Verify user account exists in Supabase
- Check email hasn't been deleted
- Verify password is correct
- Clear browser cache/cookies
Session expired unexpectedly​
Error: Redirected to login after few minutes
Solutions:
- Check token expiration: usually 1 hour
- Implement token refresh (should be automatic)
- Verify
VITE_SUPABASE_URLand keys are correct - Check browser cookies are enabled
Cannot access admin panel​
Error: Redirected to home page or "Access denied"
Solutions:
- Verify user account has
adminrole in Supabase - Check
userstable for role field - Verify admin routes are protected correctly
- Clear cache and try again
Content & Media Issues​
Images not uploading​
Error: Upload fails or image doesn't appear
Solutions:
- Verify
VITE_CLOUDINARY_CLOUD_NAMEandVITE_CLOUDINARY_UPLOAD_PRESETare set - Check file size (max 10MB)
- Verify file is valid image format
- Check Cloudinary dashboard for errors
Video metadata not loading​
Error: YouTube videos show no thumbnail or title
Solutions:
- Verify
VITE_YOUTUBE_API_KEYis set and active - Check YouTube API is enabled in GCP console
- Verify video ID is correct
- Check API quota hasn't been exceeded
Content won't publish​
Error: Save button doesn't work or error message appears
Solutions:
- Check browser console for errors (F12)
- Verify all required fields are filled
- Check network tab for failed requests
- Verify Supabase connection is active
Email Issues​
Welcome email not sending​
Error: User created but no email received
Solutions:
- Verify SMTP credentials in
.env - Check email not in spam folder
- Verify email address is valid
- Check backend logs:
python main.py
Newsletter signup fails​
Error: Subscribe button doesn't work or shows error
Solutions:
- Verify email is valid format
- Check if email already subscribed
- Verify newsletter table exists in database
- Check backend API is running (
python main.py)
Performance Issues​
Site loads slowly​
Causes: Large bundle, unoptimized images, slow database
Solutions:
- Build and check bundle size:
npm run build - Optimize images: use Cloudinary transformations
- Enable database caching
- Check network tab in dev tools
- Use Lighthouse (Chrome DevTools) to profile
High memory usage in dev server​
Solutions:
# Restart dev server
Ctrl+C
npm run dev
# Clear node_modules if persistent
rm -rf node_modules
npm install
Deployment Issues​
Build fails on Vercel/Netlify​
Error: Build logs show errors
Solutions:
- Verify all environment variables are set
- Check node version matches local (usually 18+)
- Verify build command:
npm run build - Check for hardcoded localhost URLs
Live site shows different content than local​
Cause: Stale cache or CDN not updated
Solutions:
- Clear Vercel cache and redeploy
- Hard refresh browser (Cmd+Shift+R or Ctrl+Shift+R)
- Check environment variables match production
- Wait for CDN cache to invalidate (usually 5 min)
API calls returning 404​
Error: Requests to /api/* endpoints fail
Solutions:
- Verify
VITE_API_BASE_URLpoints to correct server - Check backend is running/deployed
- Verify endpoint exists in backend
- Check CORS headers if cross-origin
- Look at network tab to see actual URL being called
Git & Version Control​
Changes not appearing after commit​
Cause: File not actually staged or branch not updated
Solutions:
# Check status
git status
# Stage all changes
git add -A
# Check staged files
git diff --cached
# Commit
git commit -m "message"
Merge conflicts​
Solutions:
- Check affected files
- Resolve conflicts (search for
<<<<<<<) - Stage resolved files
- Commit merge
Getting Help​
Still stuck? Try these resources:
- Search docs: See Documentation Index
- Check logs:
- Frontend: Browser console (F12)
- Backend: Terminal running
python main.py - Supabase: Dashboard → Logs
- Contact support: info@agentification.academy
- Check status pages:
Last Updated: 2025-12-24
For detailed setup information, see Development Setup.