Commit Graph

310 Commits

Author SHA1 Message Date
Koen Kanters 2bca5deb66 Fix setting devices/groups to file via environment variables not working. #7807 2022-09-07 10:07:16 +02:00
Jorge Schrauwen a0255d0f2c Always treat filtered_* as full matches (#13083)
* Revert "update tests to use regex ^$ anchors"

This reverts commit 3d9bc552e9.

* utils: filterProperties should ensure full match
2022-07-11 17:24:34 +02:00
Koen Kanters 8af3ad5541 Fix crash when ZIGBEE2MQTT_CONFIG_ADVANCED_NETWORK_KEY environment variable is set to GENERATE. https://github.com/Koenkk/zigbee2mqtt/issues/12999 2022-07-08 16:58:23 +02:00
Jorge Schrauwen db021e6711 Allow regexes for filtered_attributes, filtered_cache and filtered_optimistic options (#13047)
* Ensure filtered_attributes and filtered_optimistic are also regex

Bring filtered_attributes and filtered_optimistic in line with the newer filtered_cache.
All three of them are now regex matches instead of absolute matches.

* update tests to use regex ^$ anchors

* utils: add filterProperties
2022-07-06 17:07:22 +02:00
Jorge Schrauwen dedbf336af Add filtered_cache option (#12988)
* want a way to prevent attribute from being cached

* Update filtered_cache description to be more clear

* Fix emitStateChange was returning wrong payload in to parameter

* Directly get filtered_cache from entity and forgo parameter to State.set()

* Add tests to cover filtered_cache

* Update state.ts

* Update controller.test.js

Co-authored-by: Koen Kanters <koenkanters94@gmail.com>
2022-07-02 20:33:04 +02:00
Vladimir Vitkov 326c2aaa90 Allow to specify MQTT server in secrets (#12904)
* add server, pan_id, ext_pan_id to secrets

* fix tests

* clean secrets before every test run

* add interpolation of mqtt.server, advanced.pan_id, advanced.ext_pan_id and split mqtt.user, mqtt.pass requirement

* remove pan_id and ext_pan_id from secrets processing
2022-06-27 18:42:05 +02:00
RoboMagus 402081e39d Fix EnvVar parsing of settings scheme with 'oneOf'. (#12948) 2022-06-26 16:16:44 +02:00
Koen Kanters f2e953cf18 Add group off_state option (#12868) 2022-06-18 15:47:06 +02:00
Koen Kanters 83b490a968 Add zigbee2mqtt/bridge/request/backup (#12797)
* Add backup call

* Updates
2022-06-14 20:14:01 +02:00
Koen Kanters 68035a1256 Fix restart not working (#12629) 2022-05-29 08:15:47 +00:00
Koen Kanters d0530b8214 Don't allow friendly names to include control character. #12379 2022-05-04 21:00:29 +02:00
Koen Kanters 40ef638e0e Fix null not allowed for Home Assistant device options. #12340 2022-05-03 19:39:30 +02:00
John Doe 27bc646cf6 Add home assistant name to settings schema (#12191)
Co-authored-by: nurikk <ainur@yojee.com>
2022-04-16 10:27:41 +08:00
Koen Kanters 8bf06901c2 Availability for groups (#11626)
* Availability for groups. https://github.com/Koenkk/zigbee2mqtt/issues/9176

* Updates

* Fix
2022-03-14 15:51:02 +01:00
Koen Kanters e5d6bd1d68 Don't cache no_occupancy_since. https://github.com/Koenkk/zigbee2mqtt/issues/11183 2022-03-07 18:38:36 +01:00
Andrew Berry 364a6dd2aa Only colorize output if logging to a tty (#11645) 2022-03-02 20:07:22 +01:00
Koen Kanters 41ece365aa Allow to configure availablility payloads to be a JSON object. #10802 2022-02-02 19:28:44 +01:00
Koen Kanters 73f02bfee3 Fix crash when availability is enabled per device. #11184 2022-02-02 17:39:45 +01:00
Koen Kanters 912360c1f0 Fix availability passive device timeout config. https://github.com/Koenkk/zigbee2mqtt/pull/10437 2022-01-31 17:28:08 +01:00
Joshua Spence 1a70b80282 Flush logger before exiting process (#10905)
* Wait for async logs

* Fix tests

* Better solution

Based on https://stackoverflow.com/a/59260151

* Fix lint/test coverage

Co-authored-by: Koen Kanters <koenkanters94@gmail.com>
2022-01-26 15:57:51 +00:00
Koen Kanters 30177b0db4 Restructure settings (#10437)
* -

* deep copy schema

* -

* -

* -

* -

* -

* -

* -

* -

* -

* -

* -

* -
2022-01-09 22:28:44 +01:00
Oleksandr Masliuchenko 16842a3e72 Add posibility to have local OTA index (#10141)
* Add a configuration option to override OTA index file

* Cleanup

* Code review corrections

* Move zigbee_ota_override_index_location to ota section of the configuration file

* Suport both local and remote (HTTP) OTA override index files

* Updates

* updates

Co-authored-by: Koen Kanters <koenkanters94@gmail.com>
2022-01-04 20:29:17 +01:00
Rotzbua e8caddaf63 Fix typo: suppress (#10490)
* Fix typo: suppress

* Fix typo: discovered
2022-01-02 07:11:39 +00:00
Koen Kanters 7592c627c2 Fix typo in settings.schema.json. https://github.com/Koenkk/zigbee2mqtt/pull/9803 2021-12-08 17:46:17 +01:00
Koen Kanters d4f560d198 Validate QOS value. https://github.com/Koenkk/zigbee2mqtt/issues/9962 2021-12-07 18:52:54 +01:00
amadeo-alex df182be21f Fix log commit hash newline (#9897)
* Added trim operation before commitHash is returned

* Update utils.ts

Co-authored-by: Koen Kanters <koenkanters94@gmail.com>
2021-11-30 12:24:36 +08:00
Koen Kanters 65f7fc0532 Fix lint errors of 0a7a477281 2021-11-27 09:36:03 +01:00
Koen Kanters 0a7a477281 Send only 1 MQTT message when last_seen is enabled and Zigbee message is received. https://github.com/Koenkk/zigbee2mqtt/issues/9519 2021-11-27 09:31:31 +01:00
tteckster 372ec315b5 Update settings.schema.json (#9803)
* Update settings.schema.json

* Update settings.schema.json
2021-11-23 18:00:44 +00:00
Pavel Sokolov 181944d2ff Fix invalid frontend.host default value in schema (#9508) 2021-11-05 19:08:34 +01:00
Koen Kanters 62bf76c11f Fix site links 2021-11-01 18:12:27 +01:00
github-actions[bot] 09383877b0 Update dependencies (#9444)
* Update dependencies

* Fix lint

Co-authored-by: Koenkk <Koenkk@users.noreply.github.com>
Co-authored-by: Koen Kanters <koenkanters94@gmail.com>
2021-11-01 18:10:54 +01:00
Koen Kanters 7415e8416d Update availability config title. https://github.com/Koenkk/zigbee2mqtt/issues/6281 2021-10-04 21:24:31 +02:00
Koen Kanters 30badb62e7 Update availabiltiy config schema. https://github.com/Koenkk/zigbee2mqtt/issues/6281 2021-10-04 17:48:05 +02:00
Koen Kanters 0282011255 Replace old availability implementation with new one (#8904)
* Update

* Updates

* More refactoringzzz

* Bindoo

* Loadz of typescripting

* Logga

* Updates

* Updates

* Updates

* Updates

* cleanup

* updates

* Fix coverage

* Fixes

* Updates

* Updates

* Replace old availability implementation with new one.
2021-10-02 10:25:43 +02:00
Koen Kanters 045ee573a0 Final TypeScript refactor (#8859)
* Update

* Updates

* More refactoringzzz

* Bindoo

* Loadz of typescripting

* Logga

* Updates

* Updates

* Updates

* Updates

* cleanup

* updates

* Fix coverage

* Fixes

* Updates

* Updates
2021-10-02 10:09:38 +02:00
Koen Kanters 8d9f14e30b Fix device configuring with endpoint ID not working. https://github.com/nurikk/zigbee2mqtt-frontend/issues/874 2021-09-29 22:00:01 +02:00
Koen Kanters 89dea86b3a Refactor HomeAssistant extension to TypeScript 2021-09-22 18:04:57 +02:00
Koen Kanters ca3c6ce32f More TypeScript refactoring (#8797)
* ts

* Updates
2021-09-18 18:23:28 +02:00
Koen Kanters fb081316e2 More TypeScript refactoring (#8721)
* Update

* u

* Updates

* Updates

* updates

* Updates

* Update
2021-09-11 14:51:29 +02:00
Koen Kanters 4125ae0888 TypeScript refactoring (#8567)
* Updates

* Updates

* Updates

* Rename

* Updates

* updates

* Updates

* Updates
2021-09-01 20:39:17 +02:00
Koen Kanters 17b2315d89 Enable Home Assistant availability_mode all only when new availability feature is enabled. #6281 2021-08-28 16:20:02 +02:00
Koen Kanters 22430631d2 Honour legacy availability options and retrieve state when device reconnects #6281 (#8545)
* Availability

* Updates
2021-08-28 10:08:09 +02:00
Koen Kanters 3774a78134 Migrate utils to typescript. 2021-08-25 20:11:55 +02:00
Koen Kanters 9129f95c39 Add availability_mode for Home Assistant and publish availability only when its enabled for that device. #6281 2021-08-23 19:24:10 +02:00
z-x-f a8545d08b6 Add usb to endpoint names (#8370)
Co-authored-by: Koen Kanters <koenkanters94@gmail.com>
2021-08-15 20:27:43 +02:00
Koen Kanters 17dc22fdb0 Move source map install to index.js 2021-08-14 09:59:31 +02:00
Koen Kanters f571938efc Migrate settings.js to TypeScript. 2021-07-21 22:14:33 +02:00
Koen Kanters 7b65dc631b Enable TypeScript (#8074)
* Enable Typescript

* Fix tests

* Fix tests again

* Automatically (re)build

* Updates

* Updates

* Update shrinkwrap

* Enable sourcemaps
2021-07-21 19:35:14 +02:00
github-actions[bot] d67649e458 Update dependencies (#7956)
* Update dependencies

* Update dependencies

* updates

* update

Co-authored-by: Koenkk <Koenkk@users.noreply.github.com>
Co-authored-by: Koen Kanters <koenkanters94@gmail.com>
2021-07-05 22:12:50 +02:00