Files
trading_bot_v3/RESTART_DOCKER_INSTRUCTIONS.md
mindesbunister ff4e9737fb fix: timeframe handling and progress tracking improvements
- Fix timeframe parameter handling in enhanced-screenshot API route
- Support both 'timeframe' (singular) and 'timeframes' (array) parameters
- Add proper sessionId propagation for real-time progress tracking
- Enhance MACD analysis prompt with detailed crossover definitions
- Add progress tracker service with Server-Sent Events support
- Fix Next.js build errors in chart components (module variable conflicts)
- Change dev environment port from 9000:3000 to 9001:3000
- Improve AI analysis layout detection logic
- Add comprehensive progress tracking through all service layers
2025-07-17 10:41:18 +02:00

1.9 KiB

🔄 Docker Container Restart Required

Why Restart is Needed

You need to restart your Docker container because we made the following changes:

  1. Changed API imports: Updated /app/api/enhanced-screenshot/route.js to use enhanced-screenshot.ts instead of enhanced-screenshot-simple.ts
  2. Added progress tracking: The new implementation uses real-time progress tracking with EventEmitter
  3. New API endpoint: Added /app/api/progress/[sessionId]/stream/route.ts for Server-Sent Events
  4. Updated service logic: Modified core screenshot capture logic with progress tracking

Restart Commands

For Development Environment:

# Stop current containers
npm run docker:down

# Rebuild and start with development config
npm run docker:dev

# Or if you want to see logs immediately:
npm run docker:up:build

For Production Environment:

# Stop production containers
npm run docker:prod:down

# Rebuild and start production
npm run docker:prod:build
npm run docker:prod:up

What to Expect After Restart

Real-time progress tracking: Progress bar will update as each step completes Smooth animations: CSS animations will work with the new progress data Live step updates: Each step (init, auth, navigation, loading, capture, analysis) will show in real-time Better user experience: No more waiting for the entire process to complete before seeing progress

Troubleshooting

If animations still don't work after restart:

  1. Check browser console for JavaScript errors
  2. Verify EventSource connection in Network tab (should see progress/[sessionId]/stream)
  3. Check Docker logs: npm run docker:logs
  4. Force rebuild: npm run docker:build:no-cache && npm run docker:up

Test the Fix

  1. Go to /analysis page
  2. Select a symbol (e.g., BTCUSD)
  3. Click "Analyze"
  4. You should see progress steps moving in real-time as they complete