Repository navigation
Conversation
Update README, add Alpaca test, and enhance PR summary
Fix Windows image paths and add SSL verification for image URLs
Introduce and refine system architecture documentation and diagrams
Modular Refactor, Multi-Client Support, and UI/Config Enhancements
Improve client list display and add ASCOM status tooltip
Implement client heartbeats, improve display formatting, and fix UI
Make MQTT and Home Assistant settings optional
Bugfix: Fix client connection duration display in UI
Optimize Docker build caching and add parallel job flags
Fix device detection label case sensitivity and setup title format
Enhance configuration safety, fix regressions, and sanitize settings
Introduce External API, enhance timestamps, and update documentation
Adjust styling for detection items in setup page
The previous change moved the "False unless connected" gate out of is_safe() and into the Alpaca issafe/devicestate routes, keyed per client. That still blocked the use case in issue #117: a roof controller that polls /api/v1/safetymonitor/0/issafe directly and never sends Connected=true kept reading False while the dashboard showed Safe. The ASCOM spec never requires False when not connected and ConformU dropped that check on 2025-03-16, so the gate is removed and issafe, devicestate, the external API, the dashboard and MQTT now all report the debounced detector state. tests/conftest.py stubs keras.models when TensorFlow is not installed so the route-level unit tests run without the model stack.
Improve Safety State Reporting and MQTT Reconnect Availability
The safety monitor could keep reporting safe while the camera image stopped updating or detection kept failing, leaving the observatory open on stale data. Refs #120 - Image hash staleness limit: max_image_age_sec (default 600, 0 disables); startup requires one new frame before reporting safe - Detection-failure limit: max(180, 3x update interval) - Both commit unsafe immediately; recovery waits debounce_to_safe_sec - Home Assistant data availability topic plus Safe binary_sensor - Legacy MQTT is_safe field - Setup page field with live preview - Dashboard image row - External API image object - Tests for stale fail-safe and image status API, shared conftest
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.
📋 Overview
This pull request significantly enhances the safety monitoring system by introducing fail-safe mechanisms for stale camera images and persistent detection failures. It refines how the safety status is reported across various interfaces, including Alpaca, MQTT, the dashboard, and an external API, ensuring more accurate and reliable observatory safety.
🔄 Changes by Category
max_image_age_sec) or if detection continuously fails.Safebinary sensor for improved integration.IsSafevalue is served to all Alpaca clients, removing the previous "False unless connected" gate.is_safefield for backward compatibility.max_image_age_secto the configuration, allowing users to define the image hash staleness limit.readme.mdto reflect new Home Assistant integration details.docs/EXTERNAL_API.mdto document the new image object status.test_stale_failsafe.py,test_image_status_api.py) for the stale data fail-safe logic and image status API.conftest.pyto stubkeras.models, allowing route-level unit tests to run without TensorFlow.issafegate and MQTT reconnect functionality.📊 Analyzed 22 commit(s) | 🕐 Updated: 2026-10-09T11:55:49.726Z | Generated by GitHub Actions