Skip to content

fix: cron closure bug, reload hooks, and command robustness#1723

Merged
seriousm4x merged 2 commits into
seriousm4x:masterfrom
monstercjz:bugfix/automated-wake-logic
Apr 1, 2026
Merged

fix: cron closure bug, reload hooks, and command robustness#1723
seriousm4x merged 2 commits into
seriousm4x:masterfrom
monstercjz:bugfix/automated-wake-logic

Conversation

@monstercjz

Copy link
Copy Markdown
Contributor

This PR addresses several critical issues found during automated wake-on-lan and ping monitoring:

  1. Cron Closure Bug: Replaces loop variable reference with a fresh record lookup inside cron jobs to ensure scheduled tasks use the correct device data.
    1. Automated Cron Reload: Monitors ip and ping_cmd fields for changes to trigger an automatic reload of scheduled tasks without requiring a container restart.
    1. Custom Ping Robustness: Updates PingDevice to treat any non-zero exit code (e.g., nc timeouts) as an "offline" status instead of a process error.
    1. Wake Logic Robustness: Ensures WakeDevice returns immediately on process start failure and prevents device status from being stuck in "pending" when a command finishes execution.

@seriousm4x seriousm4x merged commit 6d53e9e into seriousm4x:master Apr 1, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants