mirror of
https://github.com/home-assistant/core.git
synced 2025-06-25 01:21:51 +02:00
Upgrade url-normalize to 2.2.1 (#143751)
This commit is contained in:
@ -276,11 +276,12 @@ class ConfigFlowHandler(ConfigFlow, domain=DOMAIN):
|
||||
if TYPE_CHECKING:
|
||||
assert discovery_info.ssdp_location
|
||||
url = url_normalize(
|
||||
discovery_info.upnp.get(
|
||||
ATTR_UPNP_PRESENTATION_URL,
|
||||
f"http://{urlparse(discovery_info.ssdp_location).hostname}/",
|
||||
)
|
||||
discovery_info.upnp.get(ATTR_UPNP_PRESENTATION_URL)
|
||||
or f"http://{urlparse(discovery_info.ssdp_location).hostname}/"
|
||||
)
|
||||
if TYPE_CHECKING:
|
||||
# url_normalize only returns None if passed None, and we don't do that
|
||||
assert url is not None
|
||||
|
||||
unique_id = discovery_info.upnp.get(
|
||||
ATTR_UPNP_SERIAL, discovery_info.upnp[ATTR_UPNP_UDN]
|
||||
|
@ -9,7 +9,7 @@
|
||||
"requirements": [
|
||||
"huawei-lte-api==1.11.0",
|
||||
"stringcase==1.2.0",
|
||||
"url-normalize==2.2.0"
|
||||
"url-normalize==2.2.1"
|
||||
],
|
||||
"ssdp": [
|
||||
{
|
||||
|
@ -1,7 +1,7 @@
|
||||
"""Config flow for Samsung SyncThru."""
|
||||
|
||||
import re
|
||||
from typing import Any
|
||||
from typing import TYPE_CHECKING, Any
|
||||
from urllib.parse import urlparse
|
||||
|
||||
from pysyncthru import ConnectionMode, SyncThru, SyncThruAPINotSupported
|
||||
@ -44,12 +44,14 @@ class SyncThruConfigFlow(ConfigFlow, domain=DOMAIN):
|
||||
await self.async_set_unique_id(discovery_info.upnp[ATTR_UPNP_UDN])
|
||||
self._abort_if_unique_id_configured()
|
||||
|
||||
self.url = url_normalize(
|
||||
discovery_info.upnp.get(
|
||||
ATTR_UPNP_PRESENTATION_URL,
|
||||
f"http://{urlparse(discovery_info.ssdp_location or '').hostname}/",
|
||||
)
|
||||
norm_url = url_normalize(
|
||||
discovery_info.upnp.get(ATTR_UPNP_PRESENTATION_URL)
|
||||
or f"http://{urlparse(discovery_info.ssdp_location or '').hostname}/"
|
||||
)
|
||||
if TYPE_CHECKING:
|
||||
# url_normalize only returns None if passed None, and we don't do that
|
||||
assert norm_url is not None
|
||||
self.url = norm_url
|
||||
|
||||
for existing_entry in (
|
||||
x for x in self._async_current_entries() if x.data[CONF_URL] == self.url
|
||||
|
@ -6,7 +6,7 @@
|
||||
"documentation": "https://www.home-assistant.io/integrations/syncthru",
|
||||
"iot_class": "local_polling",
|
||||
"loggers": ["pysyncthru"],
|
||||
"requirements": ["PySyncThru==0.8.0", "url-normalize==2.2.0"],
|
||||
"requirements": ["PySyncThru==0.8.0", "url-normalize==2.2.1"],
|
||||
"ssdp": [
|
||||
{
|
||||
"deviceType": "urn:schemas-upnp-org:device:Printer:1",
|
||||
|
@ -6,7 +6,7 @@
|
||||
"config_flow": true,
|
||||
"documentation": "https://www.home-assistant.io/integrations/zwave_me",
|
||||
"iot_class": "local_push",
|
||||
"requirements": ["zwave-me-ws==0.4.3", "url-normalize==2.2.0"],
|
||||
"requirements": ["zwave-me-ws==0.4.3", "url-normalize==2.2.1"],
|
||||
"zeroconf": [
|
||||
{
|
||||
"type": "_hap._tcp.local.",
|
||||
|
2
requirements_all.txt
generated
2
requirements_all.txt
generated
@ -3001,7 +3001,7 @@ upcloud-api==2.6.0
|
||||
# homeassistant.components.huawei_lte
|
||||
# homeassistant.components.syncthru
|
||||
# homeassistant.components.zwave_me
|
||||
url-normalize==2.2.0
|
||||
url-normalize==2.2.1
|
||||
|
||||
# homeassistant.components.uvc
|
||||
uvcclient==0.12.1
|
||||
|
2
requirements_test_all.txt
generated
2
requirements_test_all.txt
generated
@ -2424,7 +2424,7 @@ upcloud-api==2.6.0
|
||||
# homeassistant.components.huawei_lte
|
||||
# homeassistant.components.syncthru
|
||||
# homeassistant.components.zwave_me
|
||||
url-normalize==2.2.0
|
||||
url-normalize==2.2.1
|
||||
|
||||
# homeassistant.components.uvc
|
||||
uvcclient==0.12.1
|
||||
|
Reference in New Issue
Block a user