You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
feat: Remove notification feature and blueprints to simplify integration scope
- Completed removal of the notification system (`notify_on_failure`) and all related code across 9 files.
- Deleted blueprints directory and updated documentation to reflect the changes.
- Verified no lingering references to removed features and ensured all tests pass.
- Updated version to 0.2.0 and created CHANGELOG.md to document changes.
Copy file name to clipboardExpand all lines: CLAUDE.md
+51-35Lines changed: 51 additions & 35 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,6 +1,7 @@
1
1
# CLAUDE.md
2
2
3
-
This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository.
3
+
This file provides guidance to Claude Code (claude.ai/code) when working with code in
4
+
this repository.
4
5
5
6
## Git Workflow
6
7
@@ -9,9 +10,12 @@ This file provides guidance to Claude Code (claude.ai/code) when working with co
9
10
10
11
## Project Overview
11
12
12
-
HA-Light-Controller is a Home Assistant custom integration providing reliable light control with state verification, automatic retries, and preset management. It ensures lights actually reach their target state after commands are sent. Distributed via HACS.
13
+
HA-Light-Controller is a Home Assistant custom integration providing reliable light
14
+
control with state verification, automatic retries, and preset management. It ensures
15
+
lights actually reach their target state after commands are sent. Distributed via HACS.
13
16
14
-
**Scope**: Focused on core light control with verification/retry and preset management. Notification feature and blueprints removed in v0.2.0.
17
+
**Scope**: Focused on core light control with verification/retry and preset management.
18
+
Notification feature and blueprints removed in v0.2.0.
15
19
16
20
## Environment
17
21
@@ -20,14 +24,15 @@ HA-Light-Controller is a Home Assistant custom integration providing reliable li
20
24
21
25
## Home Assistant Environment Constraints
22
26
23
-
**Blocking calls freeze the entire HA instance.** All I/O must be async or use `hass.async_add_executor_job()`.
27
+
**Blocking calls freeze the entire HA instance.** All I/O must be async or use
`_expand_entity()` resolves `light.*` groups and `group.*` helper groups to individual `light.` entities. Uses `_get_state()` directly for attribute access.
125
+
`_expand_entity()` resolves `light.*` groups and `group.*` helper groups to individual
126
+
`light.` entities. Uses `_get_state()` directly for attribute access.
120
127
121
128
### Service Registration
122
129
123
-
Services are registered individually in `async_setup()` (not `async_setup_entry()`). This ensures they persist across config entry reloads. Each handler resolves the active entry at call time via `_get_loaded_entry()`:
130
+
Services are registered individually in `async_setup()` (not `async_setup_entry()`).
131
+
This ensures they persist across config entry reloads. Each handler resolves the active
HA Light Controller adds state verification and automatic retries to light commands. When you call `light.turn_on`, Home Assistant sends the command once and assumes success. This integration verifies that entities actually reached the target state and retries if they didn't.
14
+
HA Light Controller adds state verification and automatic retries to light commands.
15
+
When you call `light.turn_on`, Home Assistant sends the command once and assumes
16
+
success. This integration verifies that entities actually reached the target state and
17
+
retries if they didn't.
16
18
17
-
This solves the common problem of lights occasionally missing commands due to network congestion, Zigbee/Z-Wave mesh issues, or unresponsive devices. Instead of building retry logic into every script and automation, HA Light Controller handles verification centrally with configurable tolerances and backoff strategies.
19
+
This solves the common problem of lights occasionally missing commands due to network
20
+
congestion, Zigbee/Z-Wave mesh issues, or unresponsive devices. Instead of building
21
+
retry logic into every script and automation, HA Light Controller handles verification
22
+
centrally with configurable tolerances and backoff strategies.
18
23
19
24
### How It Works
20
25
@@ -26,30 +31,37 @@ This solves the common problem of lights occasionally missing commands due to ne
26
31
27
32
## Key Features
28
33
29
-
-**State verification** - Confirms entities reached target brightness, color, and temperature within configurable tolerances
34
+
-**State verification** - Confirms entities reached target brightness, color, and
35
+
temperature within configurable tolerances
30
36
-**Automatic retries** - Configurable retry attempts with exponential backoff
31
-
-**Group expansion** - Automatically expands `light.*` and `group.*` entities to individual lights
32
-
-**Per-entity overrides** - Set different attributes for each light in a single service call via the `targets` parameter
37
+
-**Group expansion** - Automatically expands `light.*` and `group.*` entities to
38
+
individual lights
39
+
-**Per-entity overrides** - Set different attributes for each light in a single service
40
+
call via the `targets` parameter
33
41
-**Presets** - Store light configurations as button entities for one-tap activation
34
42
35
43
## Installation
36
44
37
45
### HACS
38
46
39
-
1. Add `https://github.com/L3DigitalNet/HA-Light-Controller` as a custom repository (Integration)
47
+
1. Add `https://github.com/L3DigitalNet/HA-Light-Controller` as a custom repository
48
+
(Integration)
40
49
2. Install "HA Light Controller"
41
50
3. Restart Home Assistant
42
51
43
52
### Manual
44
53
45
-
1. Copy `custom_components/ha_light_controller` to your `config/custom_components/` directory
54
+
1. Copy `custom_components/ha_light_controller` to your `config/custom_components/`
55
+
directory
46
56
2. Restart Home Assistant
47
57
48
58
## Configuration
49
59
50
-
Add the integration via **Settings** → **Devices & Services** → **Add Integration** → "Light Controller".
60
+
Add the integration via **Settings** → **Devices & Services** → **Add Integration** →
61
+
"Light Controller".
51
62
52
-
Configuration options include default brightness, transition time, verification tolerances (brightness, RGB, Kelvin), retry settings, and success logging.
63
+
Configuration options include default brightness, transition time, verification
64
+
tolerances (brightness, RGB, Kelvin), retry settings, and success logging.
53
65
54
66
## Usage
55
67
@@ -61,7 +73,7 @@ data:
61
73
entities:
62
74
- light.living_room_ceiling
63
75
- light.living_room_lamp
64
-
state: "off"
76
+
state: 'off'
65
77
```
66
78
67
79
### Per-Entity Overrides
@@ -84,24 +96,28 @@ data:
84
96
85
97
### Presets
86
98
87
-
Create and edit presets via the integration options UI or programmatically. The UI supports per-entity configuration - set different brightness, color, and state for each light in the preset. Preset deletion includes a confirmation step.
99
+
Create and edit presets via the integration options UI or programmatically. The UI
100
+
supports per-entity configuration - set different brightness, color, and state for each
101
+
light in the preset. Preset deletion includes a confirmation step.
88
102
89
103
```yaml
90
104
service: ha_light_controller.create_preset
91
105
data:
92
-
name: "Movie Night"
106
+
name: 'Movie Night'
93
107
entities:
94
108
- light.living_room
95
109
- light.tv_backlight
96
110
brightness_pct: 20
97
111
color_temp_kelvin: 2700
98
112
```
99
113
100
-
Each preset creates a `button.*` entity for activation and a `sensor.*` entity for status tracking.
114
+
Each preset creates a `button.*` entity for activation and a `sensor.*` entity for
115
+
status tracking.
101
116
102
117
## Documentation
103
118
104
-
See the **[Usage Guide](USAGE.md)** for complete service parameters, configuration options, and examples.
119
+
See the **[Usage Guide](USAGE.md)** for complete service parameters, configuration
0 commit comments