Pump up default timeout from 5 to 10s

This commit is contained in:
Lonami Exo
2018-06-17 11:46:56 +02:00
parent d18ee9ecc5
commit 226c35ff8f
5 changed files with 10 additions and 14 deletions

View File

@@ -11,7 +11,6 @@ Said subclasses need not to worry about reconnecting either, and
should let the errors propagate instead.
"""
import abc
from datetime import timedelta
class Connection(abc.ABC):
@@ -21,13 +20,13 @@ class Connection(abc.ABC):
Subclasses should implement the actual protocol
being used when encoding/decoding messages.
"""
def __init__(self, *, loop, proxy=None, timeout=timedelta(seconds=5)):
def __init__(self, *, loop, timeout, proxy=None):
"""
Initializes a new connection.
:param loop: the event loop to be used.
:param proxy: whether to use a proxy or not.
:param timeout: timeout to be used for all operations.
:param proxy: whether to use a proxy or not.
"""
self._loop = loop
self._proxy = proxy