Commit Graph

152 Commits

Author SHA1 Message Date
Cody Cutrer
7c8fe077f2 [mqtt.homeassistant] Implement regex_findall and regex_findall_index filters (#17895)
Signed-off-by: Cody Cutrer <cody@cutrer.us>
Signed-off-by: Ciprian Pascu <contact@ciprianpascu.ro>
2025-01-02 09:49:34 +02:00
Holger Friedrich
de74eb51e9 Prepare for OH 5.0.0 (#17906)
* Switch to 5.0.0-SNAPSHOT
* Fix spotless after unleash
* resolve itest runbundles

Signed-off-by: Holger Friedrich <mail@holger-friedrich.de>
Signed-off-by: Ciprian Pascu <contact@ciprianpascu.ro>
2025-01-02 09:49:34 +02:00
openhab-bot
7778934d07 [unleash-maven-plugin] Preparation for next development cycle.
Signed-off-by: Ciprian Pascu <contact@ciprianpascu.ro>
2025-01-02 09:49:34 +02:00
Cody Cutrer
dcf2a1aa6a [mqtt.homeassistant] Document new channels from #17659 (#17880)
Signed-off-by: Cody Cutrer <cody@cutrer.us>
Signed-off-by: Ciprian Pascu <contact@ciprianpascu.ro>
2025-01-02 09:49:34 +02:00
Cody Cutrer
573959ee59 [mqtt.homeassistant] fix unbounded growth of config for device_trigger (#17894)
Because of how it shares a channel, whenever openHAB was rebooted and it
would first restore the device trigger components from the channel configuration,
and then from the MQTT message, it didn't identify it as the same component
as before, and so would merge into another instance of itself. My Things.json
is normally 13MB, and had grown to 545MB, and my openHAB was constantly having
memory issues! So now just make sure we only keep unique information, which
will automatically clean up anyone in a bad state.

Signed-off-by: Cody Cutrer <cody@cutrer.us>
Signed-off-by: Ciprian Pascu <contact@ciprianpascu.ro>
2025-01-02 09:49:34 +02:00
openhab-bot
16463b8f44 New Crowdin updates (#17866)
* New translations mail.properties (French)

* New translations exec.properties (French)

* New translations netatmo.properties (French)

* New translations icalendar.properties (French)

* New translations mqtt.properties (Italian)

* New translations mail.properties (French)

* New translations exec.properties (French)

Signed-off-by: Ciprian Pascu <contact@ciprianpascu.ro>
2025-01-02 09:49:33 +02:00
Cody Cutrer
8803ad0c0a [mqtt.homeassistant] Update Jinjava to 2.7.4 (#17858)
* [mqtt.homeassistant] Update Jinjava to 2.7.4

Which includes support for break/continue, which is what Zigbee2MQTT's
new event component uses in their template.

Signed-off-by: Cody Cutrer <cody@cutrer.us>

* update bndrun file

Signed-off-by: Cody Cutrer <cody@cutrer.us>

---------

Signed-off-by: Cody Cutrer <cody@cutrer.us>
Signed-off-by: Ciprian Pascu <contact@ciprianpascu.ro>
2025-01-02 09:49:33 +02:00
Cody Cutrer
74329618b5 [mqtt.homeassistant] Implement WaterHeater (#17859)
* [mqtt.homeassistant] Implement WaterHeater

Signed-off-by: Cody Cutrer <cody@cutrer.us>
Signed-off-by: Ciprian Pascu <contact@ciprianpascu.ro>
2025-01-02 09:49:33 +02:00
Cody Cutrer
56c55a9604 [mqtt.homeassistant] Implement Humidifier (#17853)
* [mqtt.homeassistant] Implement Humidifier

Signed-off-by: Cody Cutrer <cody@cutrer.us>

* remove debug logging from test

Signed-off-by: Cody Cutrer <cody@cutrer.us>
Signed-off-by: Ciprian Pascu <contact@ciprianpascu.ro>
2025-01-02 09:49:33 +02:00
Cody Cutrer
0b09aaf475 [mqtt.homeassistant] Implement Tag Scanner (#17852)
Signed-off-by: Cody Cutrer <cody@cutrer.us>
Signed-off-by: Ciprian Pascu <contact@ciprianpascu.ro>
2025-01-02 09:49:32 +02:00
Cody Cutrer
cbb88c4e50 [mqtt.homeassistant] Fix thing consistency for existing things when a device adds or removes components (#17851)
* [mqtt.homeassistant] gracefully handle a component's discovery info being deleted

Signed-off-by: Cody Cutrer <cody@cutrer.us>
Signed-off-by: Ciprian Pascu <contact@ciprianpascu.ro>
2025-01-02 09:49:32 +02:00
Cody Cutrer
091dc80e2a [mqtt.homeassistant] fix multi-speed fans (#17813)
* fix step math so that the state description represents the step
   scaled to 0-100%

Signed-off-by: Cody Cutrer <cody@cutrer.us>
Signed-off-by: Ciprian Pascu <contact@ciprianpascu.ro>
2025-01-02 09:49:32 +02:00
openhab-bot
a75143239c New translations mqtt.properties (Italian) (#17832)
Signed-off-by: Ciprian Pascu <contact@ciprianpascu.ro>
2025-01-02 09:49:31 +02:00
Cody Cutrer
6398651ceb [mqtt.homeassistant] Implement Device Tracker (#17831)
* [mqtt.homeassistant] implement Device Tracker

Signed-off-by: Cody Cutrer <cody@cutrer.us>
Signed-off-by: Ciprian Pascu <contact@ciprianpascu.ro>
2025-01-02 09:49:31 +02:00
Cody Cutrer
f103c8dfbf [mqtt.homeassistant] Fix duplicate component resolution when unique_id is set (#17803)
* [mqtt.homeassistant] fix duplicate component resolution when unique_id is set

unique_id is only unique per component type. so we need to a) take that into
account, and b) use that when resolving duplicates

Signed-off-by: Cody Cutrer <cody@cutrer.us>
Signed-off-by: Ciprian Pascu <contact@ciprianpascu.ro>
2025-01-02 09:49:30 +02:00
VasekCejka
8bdedde8a0 [mqtt.homeassistant] Add missing climate properties (#17659)
* Added support for humidity and preset_modes

Signed-off-by: Václav Čejka <V.Cejka@seznam.cz>
Signed-off-by: VasekCejka <150804231+VasekCejka@users.noreply.github.com>
Signed-off-by: Ciprian Pascu <contact@ciprianpascu.ro>
2025-01-02 09:49:26 +02:00
Cody Cutrer
abbd1b9daa [mqtt.homeassistant] document which channels a component might have (#17618)
* [mqtt.homeassistant] document which channels a component might have

Signed-off-by: Cody Cutrer <cody@cutrer.us>
Signed-off-by: Ciprian Pascu <contact@ciprianpascu.ro>
2025-01-02 09:49:25 +02:00
Cody Cutrer
c9351b3dcb [mqtt.homeassistant] Implement Text (#17624)
* [mqtt.homeassistant] Implement Text

Signed-off-by: Cody Cutrer <cody@cutrer.us>
Signed-off-by: Ciprian Pascu <contact@ciprianpascu.ro>
2025-01-02 09:49:24 +02:00
Cody Cutrer
e95ab29e6f [mqtt.homeassistant] bring AlarmControlPanel in line with current documentation (#17607)
* [mqtt.homeassistant] bring AlarmControlPanel in line with current documentation

Signed-off-by: Cody Cutrer <cody@cutrer.us>
Signed-off-by: Ciprian Pascu <contact@ciprianpascu.ro>
2025-01-02 09:49:24 +02:00
Cody Cutrer
d74eb297b0 [mqtt.homeassistant] Implement Valve (#17622)
Signed-off-by: Cody Cutrer <cody@cutrer.us>
Signed-off-by: Ciprian Pascu <contact@ciprianpascu.ro>
2025-01-02 09:49:24 +02:00
Cody Cutrer
76315ac83d [mqtt.homeassistant] drop support for legacy schema vacuums (#17617)
Home Assistant dropped it in 2024.2.
See https://github.com/home-assistant/core/pull/107274

Signed-off-by: Cody Cutrer <cody@cutrer.us>
Signed-off-by: Ciprian Pascu <contact@ciprianpascu.ro>
2025-01-02 09:49:24 +02:00
Cody Cutrer
df8d7e28ae [mqtt.homeassistant] JSON Attributes can exist on BinarySensor (#17608)
also fix the conditional for JSON attributes on other components,
and make the channel read only.

Signed-off-by: Cody Cutrer <cody@cutrer.us>
Signed-off-by: Ciprian Pascu <contact@ciprianpascu.ro>
2025-01-02 09:49:23 +02:00
Cody Cutrer
0deda9d22b [mqtt.homeassistant] JSON Attributes can exist on Climate (#17610)
Signed-off-by: Cody Cutrer <cody@cutrer.us>
Signed-off-by: Ciprian Pascu <contact@ciprianpascu.ro>
2025-01-02 09:49:23 +02:00
Cody Cutrer
5e040e3dc4 [mqtt.homeassistant] JSON Attributes can exist on Cover (#17611)
Signed-off-by: Cody Cutrer <cody@cutrer.us>
Signed-off-by: Ciprian Pascu <contact@ciprianpascu.ro>
2025-01-02 09:49:23 +02:00
Cody Cutrer
92e514dc57 [mqtt.homeassistant] JSON Attributes are supported by Scene (#17614)
Signed-off-by: Cody Cutrer <cody@cutrer.us>
Signed-off-by: Ciprian Pascu <contact@ciprianpascu.ro>
2025-01-02 09:49:23 +02:00
Cody Cutrer
e97833b041 [mqtt.homeassistant] JSON Attributes can exist on Number (#17613)
Signed-off-by: Cody Cutrer <cody@cutrer.us>
Signed-off-by: Ciprian Pascu <contact@ciprianpascu.ro>
2025-01-02 09:49:23 +02:00
Cody Cutrer
926fff034c [mqtt.homeassistant] JSON Attributes can exist on Lock (#17612)
Signed-off-by: Cody Cutrer <cody@cutrer.us>
Signed-off-by: Ciprian Pascu <contact@ciprianpascu.ro>
2025-01-02 09:49:23 +02:00
Cody Cutrer
d135e24fe4 [mqtt.homeassistant] Add support for Event component (#17599)
Signed-off-by: Cody Cutrer <cody@cutrer.us>
Signed-off-by: Ciprian Pascu <contact@ciprianpascu.ro>
2025-01-02 09:49:23 +02:00
Cody Cutrer
356aa13fb7 [mqtt.homeassistant] add JSON attributes channel to several components (#17605)
Signed-off-by: Cody Cutrer <cody@cutrer.us>
Signed-off-by: Ciprian Pascu <contact@ciprianpascu.ro>
2025-01-02 09:49:23 +02:00
Cody Cutrer
40805e9c94 [mqtt.homeassistant] bring channel ids inline with coding standards (#17604)
but only for newStyleChannels, which is already a breaking change of
most channels getting renamed for 4.3 anyway

Signed-off-by: Cody Cutrer <cody@cutrer.us>
Signed-off-by: Ciprian Pascu <contact@ciprianpascu.ro>
2025-01-02 09:49:23 +02:00
Cody Cutrer
89b4e2267d [mqtt.homeassistant] Use a single channel for all events from a single button (#17598)
Use the `subtype` field to collapse multiple DeviceAutomation components into
a single channel.

Signed-off-by: Cody Cutrer <cody@cutrer.us>
Signed-off-by: Ciprian Pascu <contact@ciprianpascu.ro>
2025-01-02 09:49:23 +02:00
Cody Cutrer
69c519e06d [mqtt.homeassistant] avoid improperly delivered triggers (#17584)
if multiple DeviceTrigger components share a topic, and each
has a payload value configured, only messages matching that
payload should be delivered to the corresponding channel

Signed-off-by: Cody Cutrer <cody@cutrer.us>
Signed-off-by: Ciprian Pascu <contact@ciprianpascu.ro>
2025-01-02 09:49:22 +02:00
Cody Cutrer
21c47c85d7 [mqtt.homeassistant] implement non-deprecated color inference for JSON Schema lights (#17529)
In particular, use the color_mode attribute to tell us which color space to parse in,
instead of trying to guess. Some devices will fill out attributes not-pertinent to
the current color mode, and their math might be... less than optimal.
Also sync color temp and color channels when the color_mode is the opposite.

Signed-off-by: Cody Cutrer <cody@cutrer.us>
Signed-off-by: Ciprian Pascu <contact@ciprianpascu.ro>
2025-01-02 09:49:20 +02:00
Cody Cutrer
f137c07dad [mqtt.homeassistant] Implement optimistic components with AutoUpdatePolicy.RECOMMEND (#17520)
Signed-off-by: Cody Cutrer <cody@cutrer.us>
Signed-off-by: Ciprian Pascu <contact@ciprianpascu.ro>
2025-01-02 09:49:19 +02:00
Cody Cutrer
2c6a0f052c [mqtt.homeassistant] fix newStyleChannels (#17491)
* [mqtt.homeassistant] fix newStyleChannels
* further simplify channel IDs

Signed-off-by: Cody Cutrer <cody@cutrer.us>
Signed-off-by: Ciprian Pascu <contact@ciprianpascu.ro>
2025-01-02 09:49:19 +02:00
Cody Cutrer
37aa25d0a6 [mqtt.homeassistant] Fix jinja usage in availability templates (#17400)
* [mqtt.homeassistant] Fix jinja usage in availability templates

Use the local Jinjava, instead of implicitly depending on the Jinja
transformation service.

Signed-off-by: Cody Cutrer <cody@cutrer.us>
Signed-off-by: Ciprian Pascu <contact@ciprianpascu.ro>
2025-01-02 09:49:17 +02:00
Cody Cutrer
53937d0c08 [mqtt.homeassistant] implement iif and is_defined jinja function and filters (#17435)
Signed-off-by: Cody Cutrer <cody@cutrer.us>
Signed-off-by: Ciprian Pascu <contact@ciprianpascu.ro>
2025-01-02 09:49:17 +02:00
Cody Cutrer
c6097cc517 [mqtt.homeassistant] Update Jinjava to 2.7.3 (#17412)
* [mqtt.homeassistant] Update Jinjava to 2.7.3

Signed-off-by: Cody Cutrer <cody@cutrer.us>
Signed-off-by: Ciprian Pascu <contact@ciprianpascu.ro>
2025-01-02 09:49:16 +02:00
Cody Cutrer
48c96f98c8 [mqtt.homeassistant] Include the details of JSON syntax errors when parsing fails (#17452)
While it's useful in general to not have to copy/paste a MQTT message into a JSON
parser to verify syntax, it also includes details about fields that are the wrong
data type that a generic JSON parser won't catch. A la #17375.

Signed-off-by: Cody Cutrer <cody@cutrer.us>
Signed-off-by: Ciprian Pascu <contact@ciprianpascu.ro>
2025-01-02 09:49:16 +02:00
Cody Cutrer
6dc2b6e478 [mqtt.homeassistant] remove channels for no-longer-configured components (#17447)
Signed-off-by: Cody Cutrer <cody@cutrer.us>
Signed-off-by: Ciprian Pascu <contact@ciprianpascu.ro>
2025-01-02 09:49:16 +02:00
Holger Friedrich
bd9a50e2ed Reduce SAT warnings (#17406)
* Reduce SAT warnings

Signed-off-by: Holger Friedrich <mail@holger-friedrich.de>
Signed-off-by: Ciprian Pascu <contact@ciprianpascu.ro>
2025-01-02 09:49:14 +02:00
Cody Cutrer
a4d083281a [mqtt.homeassistant] Fully implement Fan component (#17402)
Signed-off-by: Cody Cutrer <cody@cutrer.us>
Signed-off-by: Ciprian Pascu <contact@ciprianpascu.ro>
2025-01-02 09:49:14 +02:00
Cody Cutrer
ae8f53274d [mqtt.homeassistant] Implement template schema lights (#17399)
* [mqtt.homeassistant] implement template schema lights

Signed-off-by: Cody Cutrer <cody@cutrer.us>
Signed-off-by: Ciprian Pascu <contact@ciprianpascu.ro>
2025-01-02 09:49:14 +02:00
Cody Cutrer
5f2253e656 [mqtt.homeassistant] Use Jinjava directly (#17378)
* [mqtt.homeassistant] Use Jinjava directly

Signed-off-by: Cody Cutrer <cody@cutrer.us>
Signed-off-by: Ciprian Pascu <contact@ciprianpascu.ro>
2025-01-02 09:49:14 +02:00
J-N-K
1b7c906c5e [transform.jinja] Properly use jinjava OSGi (#17358)
Depends on https://github.com/openhab/openhab-osgiify/pull/49

Signed-off-by: Jan N. Klug <github@klug.nrw>
Signed-off-by: Ciprian Pascu <contact@ciprianpascu.ro>
2025-01-02 09:49:12 +02:00
jimtng
9fe534ca4c [mqtt.homeassistant] Update config abbreviations (#17359)
Signed-off-by: Jimmy Tanagra <jcode@tanagra.id.au>
Signed-off-by: Ciprian Pascu <contact@ciprianpascu.ro>
2025-01-02 09:49:12 +02:00
jimtng
c1307a2764 [mqtt.generic] Support chaining transformations without an intersection symbol (#17290)
* [mqtt.generic] Support chaining transformations without an intersection symbol

Signed-off-by: Jimmy Tanagra <jcode@tanagra.id.au>
Signed-off-by: Ciprian Pascu <contact@ciprianpascu.ro>
2025-01-02 09:49:12 +02:00
jimtng
bd399e8e2a [jinja] Use osgiified Jinjava (#17356)
* [jinja] Use osgiified Jinjava

Signed-off-by: Jimmy Tanagra <jcode@tanagra.id.au>
Signed-off-by: Ciprian Pascu <contact@ciprianpascu.ro>
2025-01-02 09:49:12 +02:00
openhab-bot
45ff0ea8e9 New Crowdin updates (#17285)
* New translations mqtt.properties (Italian)

Signed-off-by: Ciprian Pascu <contact@ciprianpascu.ro>
2025-01-02 09:49:09 +02:00
Cody Cutrer
795f797ab7 [mqtt.homeassistant] Fix color lights that don't specify color_mode: true (#17240)
* [mqtt.homeassistant] Fix color lights that don't specify color_mode: true

See https://github.com/home-assistant/core/pull/111676

Signed-off-by: Cody Cutrer <cody@cutrer.us>
Signed-off-by: Ciprian Pascu <contact@ciprianpascu.ro>
2025-01-02 09:49:08 +02:00