mirror of
https://github.com/rcourtman/Pulse.git
synced 2026-09-22 03:04:03 +00:00
fix: improve service error detection in installer script
- Replace overly broad npm notice detection with specific checks - Add detection for actual npm start misconfiguration in ExecStart - Separate npm errors/warnings from service configuration issues - Provide clearer troubleshooting guidance for each error type This prevents false positives when npm notices appear in logs during normal operation with direct node execution. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
@@ -1792,10 +1792,14 @@ diagnose_service_failure() {
|
||||
elif echo "$recent_logs" | grep -q "EADDRINUSE.*7655"; then
|
||||
print_error "✗ Port 7655 is already in use"
|
||||
print_error " → Another service is using the default port"
|
||||
elif echo "$recent_logs" | grep -q "npm notice.*npm install"; then
|
||||
print_error "✗ Service startup issue with npm execution"
|
||||
print_error " → The service may be misconfigured to use npm instead of direct node execution"
|
||||
print_error " → This has been fixed in recent versions - try updating the installer"
|
||||
elif echo "$recent_logs" | grep -q "ExecStart=.*npm.*start"; then
|
||||
print_error "✗ Service is misconfigured to use npm start"
|
||||
print_error " → The service should use direct node execution"
|
||||
print_error " → Re-run the installer to fix this issue"
|
||||
elif echo "$recent_logs" | grep -q "npm ERR!" || echo "$recent_logs" | grep -q "npm WARN"; then
|
||||
print_error "✗ npm-related errors detected"
|
||||
print_error " → Try running: cd $PULSE_DIR && npm install"
|
||||
print_error " → Ensure all dependencies are properly installed"
|
||||
else
|
||||
print_error "✗ Unknown service failure"
|
||||
print_error "Recent log entries:"
|
||||
|
||||
Reference in New Issue
Block a user