feat: Add Home Assistant smart device integration (Issue #366)#2435
Open
Wanbogang wants to merge 1 commit intoOpenMind:mainfrom
Open
feat: Add Home Assistant smart device integration (Issue #366)#2435Wanbogang wants to merge 1 commit intoOpenMind:mainfrom
Wanbogang wants to merge 1 commit intoOpenMind:mainfrom
Conversation
- Add home_assistant action with 3 connectors: - REST API (rest_api.py) - WebSocket (websocket.py) - MQTT (mqtt.py) - Each connector supports: - Light (on/off, brightness, color) - Switch (on/off) - Climate/thermostat (temperature, on/off) - Add HomeAssistantStateInput plugin for real-time device state monitoring - Add config/home_assistant.json5 example configuration - Add aiomqtt==2.5.0 dependency - Add 125 unit tests, all passing at 100% coverage - Ruff and pyright clean Follows OM1 action/input plugin architecture conventions.
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
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.
Summary
Implements Home Assistant smart device integration, allowing OM1 robots to control smart home devices via Home Assistant. #366
Changes
New:
src/actions/home_assistant/interface.py— definesHADeviceType,HAAction,HomeAssistantInput, and sharedCOLOR_MAPconnector/rest_api.py— REST API connectorconnector/websocket.py— WebSocket connectorconnector/mqtt.py— MQTT connectorEach connector supports:
New:
src/inputs/plugins/home_assistant.pyHomeAssistantStateInputplugin for real-time device state monitoring via REST pollingNew:
config/home_assistant.json5Updated:
pyproject.tomlaiomqtt==2.5.0dependency for MQTT connector