Soften unifiprotect EA channel message (#119641)
parent
0c3a5ae5da
commit
09aa9cf842
|
@ -53,6 +53,10 @@ SCAN_INTERVAL = timedelta(seconds=DEFAULT_SCAN_INTERVAL)
|
|||
|
||||
CONFIG_SCHEMA = cv.config_entry_only_config_schema(DOMAIN)
|
||||
|
||||
EARLY_ACCESS_URL = (
|
||||
"https://www.home-assistant.io/integrations/unifiprotect#software-support"
|
||||
)
|
||||
|
||||
|
||||
async def async_setup(hass: HomeAssistant, config: ConfigType) -> bool:
|
||||
"""Set up the UniFi Protect."""
|
||||
|
@ -122,7 +126,7 @@ async def async_setup_entry(hass: HomeAssistant, entry: UFPConfigEntry) -> bool:
|
|||
"ea_channel_warning",
|
||||
is_fixable=True,
|
||||
is_persistent=True,
|
||||
learn_more_url="https://www.home-assistant.io/integrations/unifiprotect#about-unifi-early-access",
|
||||
learn_more_url=EARLY_ACCESS_URL,
|
||||
severity=IssueSeverity.WARNING,
|
||||
translation_key="ea_channel_warning",
|
||||
translation_placeholders={"version": str(nvr_info.version)},
|
||||
|
|
|
@ -67,7 +67,7 @@
|
|||
"step": {
|
||||
"start": {
|
||||
"title": "UniFi Protect Early Access enabled",
|
||||
"description": "You are either running an Early Access version of UniFi Protect (v{version}) or opt-ed into a release channel that is not the Official Release Channel. [Home Assistant does not support Early Access versions](https://www.home-assistant.io/integrations/unifiprotect#about-unifi-early-access), so you should immediately switch to the Official Release Channel. Accidentally upgrading to an Early Access version can break your UniFi Protect integration.\n\nBy submitting this form, you have switched back to the Official Release Channel or agree to run an unsupported version of UniFi Protect, which may break your Home Assistant integration at any time."
|
||||
"description": "You are either running an Early Access version of UniFi Protect (v{version}) or opt-ed into a release channel that is not the Official Release Channel.\n\nAs these Early Access releases may not be tested yet, using it may cause the UniFi Protect integration to behave unexpectedly. [Read more about Early Access and Home Assistant]({learn_more}).\n\nSubmit to dismiss this message."
|
||||
},
|
||||
"confirm": {
|
||||
"title": "[%key:component::unifiprotect::issues::ea_channel_warning::fix_flow::step::start::title%]",
|
||||
|
|
|
@ -61,7 +61,7 @@ async def test_ea_warning_ignore(
|
|||
|
||||
flow_id = data["flow_id"]
|
||||
assert data["description_placeholders"] == {
|
||||
"learn_more": "https://www.home-assistant.io/integrations/unifiprotect#about-unifi-early-access",
|
||||
"learn_more": "https://www.home-assistant.io/integrations/unifiprotect#software-support",
|
||||
"version": str(version),
|
||||
}
|
||||
assert data["step_id"] == "start"
|
||||
|
@ -73,7 +73,7 @@ async def test_ea_warning_ignore(
|
|||
|
||||
flow_id = data["flow_id"]
|
||||
assert data["description_placeholders"] == {
|
||||
"learn_more": "https://www.home-assistant.io/integrations/unifiprotect#about-unifi-early-access",
|
||||
"learn_more": "https://www.home-assistant.io/integrations/unifiprotect#software-support",
|
||||
"version": str(version),
|
||||
}
|
||||
assert data["step_id"] == "confirm"
|
||||
|
@ -123,7 +123,7 @@ async def test_ea_warning_fix(
|
|||
|
||||
flow_id = data["flow_id"]
|
||||
assert data["description_placeholders"] == {
|
||||
"learn_more": "https://www.home-assistant.io/integrations/unifiprotect#about-unifi-early-access",
|
||||
"learn_more": "https://www.home-assistant.io/integrations/unifiprotect#software-support",
|
||||
"version": str(version),
|
||||
}
|
||||
assert data["step_id"] == "start"
|
||||
|
|
Loading…
Reference in New Issue