Ok, j’ai fait une implémentation ce matin !
J’en ai profité pour renforcer la robustesse de l’intégration, car il y avait des instabilités qui devenaient encore plus visibles avec cette nouvelle fonctionnalité.
Notamment le bug du conteneur stoppé : jusque-là, dans Gladys, si le conteneur Zigbee2mqtt était déjà arrêté, une erreur 304 était émise et on ne passait jamais à la suppression du conteneur. C’est corrigé pour toutes les intégrations
J’ai testé dans plein de cas en local sur un mini-PC, et ça marche trop bien !
Les écrans :
La PR :
master ← zigbee2mqtt-reset-button
ouvert 08:11AM - 06 Mar 26 UTC
### Pull Request check-list
To ensure your Pull Request can be accepted as fa… st as possible, make sure to review and check all of these items:
- [x] If your changes affect the code, did you write the tests?
- [x] Are tests passing? (`npm test` on both front/server)
- [x] Is the linter passing? (`npm run eslint` on both front/server)
- [x] Did you run prettier? (`npm run prettier` on both front/server)
- [x] If you are adding a new feature/service, did you run the integration comparator? (`npm run compare-translations` on front)
- [x] Did you test this pull request in real life? With real devices? If this development is a big feature or a new service, we recommend that you provide a Docker image to the community ([forum](https://community.gladysassistant.com/)) for testing before merging.
- [x] If your changes modify the API (REST or Node.js), did you modify the API documentation? (Documentation is based on comments in code)
### Description of change
Implement https://community.gladysassistant.com/t/bouton-pour-reinitialiser-lintegration-zigbee2mqtt/10097
## Summary by CodeRabbit
* **New Features**
* Factory-reset for Zigbee2MQTT with a two-step confirmation flow (visible in local mode)
* New user-facing reset UI strings in English, French and German
* Reset action available from the integration setup (admin only)
* **Bug Fixes**
* Corrected i18n/JSON formatting for Zigbee2MQTT messages and links
* More robust cleanup handling so reset/disconnect proceeds even if containers are already stopped
* **Tests**
* Added API and unit tests covering the reset endpoint and workflow
L’image Docker :
gladysassistant/gladys:zigbee2mqtt-reset-button
(Déjà buildée sur x64, en cours de build pour arm64)
Je fais une release dans l’après-midi, si vous voulez tester d’ici là c’est possible
1 « J'aime »