fix: watchdog restart gap, SHM cleanup, inter_process logger#45
Merged
Conversation
Fix 1 (watchdog.py): Add _restart_times dict to track detector restart times. Skip the stuck-detection check for 35 seconds after a restart is initiated, preventing the watchdog from missing a dead detection gap while start_or_restart() kills the old process (up to 30s). Fix 2 (app.py): Wrap shm.unlink() in try/except OSError so one failed unlink does not block cleanup of remaining shared memory segments. Fix 3 (inter_process.py): Use module-level logger.warning() instead of logging.warning() for consistent log routing. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
PR template validation failedThis PR was automatically closed because the description does not follow the pull request template. Issues found:
Please update your PR description to include all required sections from the template, then reopen this PR.
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fix 1 (watchdog.py): Add _restart_times dict to track detector restart times. Skip the stuck-detection check for 35 seconds after a restart is initiated, preventing the watchdog from missing a dead detection gap while start_or_restart() kills the old process (up to 30s).
Fix 2 (app.py): Wrap shm.unlink() in try/except OSError so one failed unlink does not block cleanup of remaining shared memory segments.
Fix 3 (inter_process.py): Use module-level logger.warning() instead of logging.warning() for consistent log routing.
Please read the contributing guidelines before submitting a PR.
Proposed change
Type of change
Additional information
For new features
AI disclosure
AI tool(s) used (e.g., Claude, Copilot, ChatGPT, Cursor):
How AI was used (e.g., code generation, code review, debugging, documentation):
Extent of AI involvement (e.g., generated entire implementation, assisted with specific functions, suggested fixes):
Human oversight: Describe what manual review, testing, and validation you performed on the AI-generated portions.
Checklist
enlocale.ruff format frigate)