Add ServiceValidationError and translation support (#102592)
* Add ServiceValidationError * Add translation support * Extend translation support to HomeAssistantError * Add translation support for ServiceNotFound exc * Frontend translation & translation_key from caller * Improve fallback message * Set websocket_api as default translation_domain * Add MQTT ServiceValidationError exception * Follow up comments * Revert removing gueard on translation_key * Revert test changes to fix CI test * Follow up comments * Fix CI test * Follow up * Improve language * Follow up comment
This commit is contained in:
parent
5cd61a0cf4
commit
54cf7010cd
12 changed files with 206 additions and 18 deletions
|
@ -32,6 +32,7 @@ ERR_NOT_ALLOWED: Final = "not_allowed"
|
|||
ERR_NOT_FOUND: Final = "not_found"
|
||||
ERR_NOT_SUPPORTED: Final = "not_supported"
|
||||
ERR_HOME_ASSISTANT_ERROR: Final = "home_assistant_error"
|
||||
ERR_SERVICE_VALIDATION_ERROR: Final = "service_validation_error"
|
||||
ERR_UNKNOWN_COMMAND: Final = "unknown_command"
|
||||
ERR_UNKNOWN_ERROR: Final = "unknown_error"
|
||||
ERR_UNAUTHORIZED: Final = "unauthorized"
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue