This document provides solutions to common issues encountered while setting up, running, and contributing to RIVETO.
- Installation Issues
- Frontend Issues
- Backend Issues
- Firebase Issues
- Environment Variables
- Build & Deployment Issues
- Git & Contribution Issues
npm ERR! code ERESOLVE
npm ERR! unable to resolve dependency treeClear npm cache:
npm cache clean --forceDelete existing dependencies:
rm -rf node_modules package-lock.json
npm installIf the issue persists:
npm install --legacy-peer-depsSyntaxError: Unexpected tokenor
npm WARN EBADENGINECheck Node version:
node -vUse Node.js 18+ (recommended):
nvm install 18
nvm use 18npm startor
npm run devfails.
Ensure dependencies are installed:
npm installVerify environment variables are configured correctly.
Restart the development server:
npm run dev- Missing environment variables
- API URL misconfiguration
- JavaScript runtime errors
Open browser Developer Tools:
F12 → Console
Check for:
- React errors
- Network request failures
- Missing configuration values
404 Not Foundor
500 Internal Server ErrorVerify backend server is running.
Check API URL configuration:
VITE_API_URL=http://localhost:5000Restart frontend after changing environment variables.
Error: Cannot find moduleInstall dependencies:
npm installCheck startup command:
npm run devor
npm startEADDRINUSEFind process using the port:
Linux/macOS:
lsof -i :5000
kill -9 <PID>Windows:
netstat -ano | findstr :5000
taskkill /PID <PID> /FAccess-Control-Allow-Originerror in browser console.
Ensure CORS middleware is configured:
app.use(cors());Or whitelist frontend origin:
origin: "http://localhost:5173"FirebaseErrorVerify:
- Firebase project is active
- Authentication provider is enabled
- API keys are correct
Example:
VITE_FIREBASE_API_KEY=your_api_key
VITE_FIREBASE_AUTH_DOMAIN=your_project.firebaseapp.comMissing or insufficient permissionsReview Firestore security rules.
Example development rule:
allow read, write: if request.auth != null;Values appear as:
undefinedEnsure:
.envfile exists- Variable names are correct
- Frontend variables use required prefixes
Example:
VITE_API_URL=http://localhost:5000Restart application after changes.
npm run buildfails.
Check TypeScript/ESLint errors:
npm run lintResolve all reported issues before building.
Verify:
- Environment variables are configured in hosting platform
- Build command is correct
- Backend URLs are production-ready
Example:
VITE_API_URL=https://api.example.comfailed to push some refsPull latest changes:
git pull origin mainResolve merge conflicts and push again.
Update branch:
git fetch origin
git merge origin/mainResolve conflicts manually.
Then:
git add .
git commit -m "Resolve merge conflicts"Before opening an issue:
- Verify Node.js version
- Reinstall dependencies
- Check environment variables
- Restart frontend and backend
- Review browser console logs
- Review terminal logs
- Confirm Firebase configuration
- Ensure backend services are running
If your issue is not covered:
-
Search existing GitHub Issues.
-
Check README setup instructions.
-
Create a new issue with:
- Operating System
- Node.js Version
- Error Logs
- Steps to Reproduce
- Screenshots (if applicable)
Providing detailed information helps maintainers resolve issues faster.