v1.5.2
π§ Bug Fix + β¨ New Features
This release fixes a critical bug introduced in earlier versions and adds two new UX features: state selection via dropdown and multi-language support.
Fixed
- β
No entities after initial setup:
async_step_finish()inconfig_flow.pywas storing trigger data inentry.datainstead ofentry.options. Sincesensor.py'sasync_setup_entryreads fromentry.options.get("counters", []), no entities were created after the initial config flow. The counter is now correctly stored inentry.optionsas{"counters": [{...}]}. - β
Backward compatibility for pre-v1.5.2 entries:
sensor.pynow falls back toentry.datawhenentry.optionshas no counters, so entries created before this fix continue to work (with a logged warning to re-create the entry for a full migration).
Added
- β¨ State selection via dropdown: The trigger state field is now a dropdown selector populated with the entity's known possible states, replacing the free-text input. Supported domains:
binary_sensor,input_boolean,switch,light,fan,lock,automation,scriptβon/offcoverβopen,closed,opening,closingalarm_control_panelβdisarmed,armed_home,armed_away,armed_night,pending,triggeredinput_selectβ options read from the entity'soptionsattribute at runtime- All other domains β current state of the entity shown as default option
- The selector supports
custom_value=True, so users can always type a state not in the list.
- β¨ Multi-language support: The UI now ships with translations for 5 languages:
- π¬π§ English (
en) - πͺπΈ Spanish (
es) - π«π· French (
fr) β new - π΅πΉ Portuguese (
pt) β new - π©πͺ German (
de) β new
- π¬π§ English (
Changed
- Config flow split:
async_step_first_triggernow only collects the entity; a newasync_step_first_trigger_statestep handles state selection via dropdown. - Config flow split:
async_step_another_triggernow only collects the entity and logic; a newasync_step_another_trigger_statestep handles state selection via dropdown. - Options flow
async_step_trigger_stateandasync_step_edit_trigger_statenow use the same dropdown selector instead of a plain text field. - Updated all translation files (
en,es,strings) to reflect the new step structure. - Updated version to 1.5.2 in
manifest.json.