You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Please check the following items and answer all the questions when reporting a bug,
otherwise it will be closed immediately.
This is NOT a site-related "bugs", e.g. some site blocks me when using curl_cffi,
UNLESS it has been verified that the reason is missing pieces in the impersonation.
A code snippet that can reproduce this bug is provided, even if it's a one-liner.
Version information will be pasted as below.
Describe the bug
Using websockets, when iterating through received messages, websockets hang on recv() most of the time. This occurs for both async and non-async implementations.
When running the code below, call either asyncio.run(ws_curl_cffi_async()) or ws_curl_cffi() multiple times to discover the issue, as occasionally it works as expected (usually on the first run).
The code also includes a snippet using Python's websocket-client library, which reliably works each time.
Separately, it would be great if a message timeout could be configured, such that recv() doesn't hang indefinitely.
This is possibly an issue related to queuing of response messages. If each message is read immediately after the send, it works more reliably, but this is only applicable to this "echo" example. For example
Please check the following items and answer all the questions when reporting a bug,
otherwise it will be closed immediately.
UNLESS it has been verified that the reason is missing pieces in the impersonation.
Describe the bug
Using websockets, when iterating through received messages, websockets hang on recv() most of the time. This occurs for both async and non-async implementations.
When running the code below, call either
asyncio.run(ws_curl_cffi_async())
orws_curl_cffi()
multiple times to discover the issue, as occasionally it works as expected (usually on the first run).The code also includes a snippet using Python's websocket-client library, which reliably works each time.
Separately, it would be great if a message timeout could be configured, such that
recv()
doesn't hang indefinitely.To Reproduce
The example below uses the websocket-client library to demonstrate the expected behavior. It works reliably each time.
pip install websocket-client==1.6.4
Expected behavior
All 19 messages should be received and printed.
Versions
Additional Information
This is possibly an issue related to queuing of response messages. If each message is read immediately after the
send
, it works more reliably, but this is only applicable to this "echo" example. For exampleThe text was updated successfully, but these errors were encountered: