Skip to content

Commit

Permalink
Move asyncio compatibility to a new package.
Browse files Browse the repository at this point in the history
  • Loading branch information
aaugustin committed Apr 7, 2023
1 parent 8c6f726 commit 6ff0ac9
Show file tree
Hide file tree
Showing 7 changed files with 4 additions and 4 deletions.
Empty file.
File renamed without changes.
File renamed without changes.
2 changes: 1 addition & 1 deletion src/websockets/legacy/client.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@
cast,
)

from ..asyncio.compatibility import asyncio_timeout
from ..datastructures import Headers, HeadersLike
from ..exceptions import (
InvalidHandshake,
Expand All @@ -44,7 +45,6 @@
from ..http import USER_AGENT
from ..typing import ExtensionHeader, LoggerLike, Origin, Subprotocol
from ..uri import WebSocketURI, parse_uri
from .compatibility import asyncio_timeout
from .handshake import build_request, check_response
from .http import read_response
from .protocol import WebSocketCommonProtocol
Expand Down
2 changes: 1 addition & 1 deletion src/websockets/legacy/protocol.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@
cast,
)

from ..asyncio.compatibility import asyncio_timeout
from ..datastructures import Headers
from ..exceptions import (
ConnectionClosed,
Expand All @@ -53,7 +54,6 @@
)
from ..protocol import State
from ..typing import Data, LoggerLike, Subprotocol
from .compatibility import asyncio_timeout
from .framing import Frame


Expand Down
2 changes: 1 addition & 1 deletion src/websockets/legacy/server.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@
cast,
)

from ..asyncio.compatibility import asyncio_timeout
from ..datastructures import Headers, HeadersLike, MultipleValuesError
from ..exceptions import (
AbortHandshake,
Expand All @@ -46,7 +47,6 @@
from ..http import USER_AGENT
from ..protocol import State
from ..typing import ExtensionHeader, LoggerLike, Origin, Subprotocol
from .compatibility import asyncio_timeout
from .handshake import build_response, check_request
from .http import read_request
from .protocol import WebSocketCommonProtocol
Expand Down
2 changes: 1 addition & 1 deletion tests/legacy/test_client_server.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
import urllib.request
import warnings

from websockets.asyncio.compatibility import asyncio_timeout
from websockets.datastructures import Headers
from websockets.exceptions import (
ConnectionClosed,
Expand All @@ -29,7 +30,6 @@
)
from websockets.http import USER_AGENT
from websockets.legacy.client import *
from websockets.legacy.compatibility import asyncio_timeout
from websockets.legacy.handshake import build_response
from websockets.legacy.http import read_response
from websockets.legacy.server import *
Expand Down

0 comments on commit 6ff0ac9

Please sign in to comment.