Troubleshooting Guide¶
Issues Fixed in This Update¶
✅ Fixed: SQLAlchemy Greenlet Error¶
Error:
Solution:
Added greenlet==3.0.3 to requirements.txt. This is required for SQLAlchemy's async operations.
To fix:
cd backend
source venv/bin/activate
pip install greenlet==3.0.3
# Or reinstall all:
pip install -r requirements.txt
✅ Fixed: npm Deprecation Warnings¶
Warnings:
- inflight@1.0.6 deprecated
- glob@7.2.3 deprecated
- boolean@3.2.0 deprecated
Solution:
Updated desktop/package.json:
- Electron: 28.0.0 → 33.2.0
- electron-builder: 24.9.1 → 25.1.8
- electron-store: 8.1.0 → 10.0.0
- Added overrides to replace deprecated packages
To fix:
Quick Fix Script¶
Run this to fix all dependencies:
Common Issues¶
1. Backend Won't Start¶
Python Version Too Old¶
Solution:
python3 --version # Check version
# If < 3.11, install newer Python
brew install python@3.11 # macOS
Missing Dependencies¶
Solution:
Port Already in Use¶
Solution:
# Find process using port 8000
lsof -i :8000
# Kill it
kill -9 <PID>
# Or use a different port
uvicorn app.main:app --port 8001
2. Frontend Issues¶
Can't Connect to Backend¶
Solution: 1. Verify backend is running:
-
Check CORS settings in
backend/app/config.py: -
Check API URL in frontend:
Vite Port Conflict¶
Solution: This is normal - Vite will use 5174, 5175, etc. Update Electron if needed:
3. Electron Issues¶
Backend Not Starting in Electron¶
Solution:
1. Check Python path in desktop/main.js:
-
Verify venv exists:
-
Test backend standalone:
Blank Electron Window¶
Solution: 1. Open DevTools (Cmd+Option+I) 2. Check Console for errors 3. Verify frontend URL:
Permission Denied¶
Solution:
4. Database Issues¶
Database Locked¶
Solution:
# Close all connections
pkill -f uvicorn
# If persistent, delete and recreate
rm ~/VibeReader/vibereader.db
# Restart backend (will recreate)
Schema Mismatch¶
Solution:
# Delete database
rm ~/VibeReader/vibereader.db
# Restart backend (will create tables)
cd backend
source venv/bin/activate
uvicorn app.main:app --reload
5. Build Issues¶
PyInstaller Not Found¶
Solution:
electron-builder Fails¶
Solution:
Debugging Tips¶
Enable Verbose Logging¶
Backend¶
# backend/app/database.py
engine = create_async_engine(
settings.database_url,
echo=True, # Enable SQL logging
)
Frontend¶
// Add to apiClient.ts
console.log('API Request:', endpoint, options);
console.log('API Response:', response);
Electron¶
// desktop/main.js
mainWindow.webContents.openDevTools(); // Always open DevTools
// Log all backend output
backendProcess.stdout.on('data', (data) => {
console.log('[Backend]', data.toString());
});
Check Logs¶
Backend Logs¶
Terminal output when running uvicorn
Frontend Logs¶
Browser/Electron DevTools Console
Database Contents¶
File System¶
Environment Variables¶
Backend (.env)¶
Frontend (.env)¶
Clean Slate Reset¶
If all else fails, start fresh:
# 1. Delete all generated files
rm -rf backend/venv
rm -rf backend/__pycache__
rm -rf desktop/node_modules
rm -rf frontend/node_modules
rm -rf ~/VibeReader
# 2. Reinstall
cd backend
python3 -m venv venv
source venv/bin/activate
pip install -r requirements.txt
cd ../desktop
npm install
cd ../frontend
npm install
# 3. Test
./start-dev.sh
Getting Help¶
Check Documentation¶
- Development Setup - Setup guide
- Migration Guide - Migration details
- Next Steps - What to do next
Verify Versions¶
# Python
python3 --version # Should be 3.11+
# Node
node --version # Should be 18+
# npm
npm --version # Should be 9+
Test Components Individually¶
-
Backend only:
-
Frontend only:
-
Desktop:
Still Having Issues?¶
- Check error messages carefully
- Search for the specific error in this guide
- Verify all dependencies are installed
- Try the clean slate reset
- Check that ports aren't in use