1
mirror of https://github.com/home-assistant/core synced 2024-09-15 17:29:45 +02:00

Reduce connection timeout to avoid config flow timeouts (#29172)

This commit is contained in:
jjlawren 2019-11-27 16:14:01 -06:00 committed by Paulus Schoutsen
parent acc10c296e
commit 88441d5f68
2 changed files with 2 additions and 2 deletions

View File

@ -77,7 +77,7 @@ class PlexServer:
self.server_choice = (
self._server_name if self._server_name else available_servers[0][0]
)
self._plex_server = account.resource(self.server_choice).connect()
self._plex_server = account.resource(self.server_choice).connect(timeout=10)
def _connect_with_url():
session = None

View File

@ -30,7 +30,7 @@ class MockResource:
self.provides = ["server"]
self._mock_plex_server = MockPlexServer(index)
def connect(self):
def connect(self, timeout):
"""Mock the resource connect method."""
return self._mock_plex_server