Improve some bugbear findings

This commit is contained in:
Matthias
2024-04-20 09:51:11 +02:00
parent 6dfc34d227
commit 927c54094a
4 changed files with 6 additions and 4 deletions

View File

@@ -201,7 +201,7 @@ async def create_client(
token,
scheme='ws',
name='default',
protocol=ClientProtocol(),
protocol=None,
sleep_time=10,
ping_timeout=10,
wait_timeout=30,
@@ -216,6 +216,8 @@ async def create_client(
:param name: The name of the producer
:param **kwargs: Any extra kwargs passed to websockets.connect
"""
if not protocol:
protocol = ClientProtocol()
while 1:
try: