---
title: "curl-cffi 0.17.0 Breaking Changes on PyPI | Since.dev"
description: "What each curl-cffi release removed, renamed or changed: 172 breaking changes in 3 versions on PyPI, each with its source."
canonical_url: https://since.dev/packages/pypi/curl-cffi
last_updated: 2026-12-04
---

# curl-cffi breaking changes

curl-cffi 0.17.0 (October 26, 2026) is its newest release with breaking changes, 42 of them. The first: Removed curl_cffi.requests.session.WebSocketError. Every breaking API change we have recorded in curl-cffi on PyPI: 172 breaking changes in 3 versions. Below, its 3 versions with breaking changes, newest first, removals and renames first, each with its source.

Updated December 4, 2026

Latest version `0.17.0`, released October 26, 2026. [Source repository](https://github.com/lexiforest/curl%5Fcffi)

Packages on PyPI run on Python. [Python end of life dates](https://since.dev/calendar/python.md).

- From [0.15.0](#v-0-15-0) to [0.17.0](#v-0-17-0): 84 breaking changes in 2 versions.

## curl-cffi 0.17.0 breaking changes

curl-cffi 0.17.0, released October 26, 2026: 42 breaking changes.

- **Removed** `curl_cffi.requests.session.WebSocketError`  

curl_cffi.requests.session.WebSocketError was removed in curl-cffi 0.17.0 [pypi.org](https://pypi.org/project/curl-cffi/0.17.0/)
- **Removed** `curl_cffi.requests.websockets.ON_CLOSE_T`  

curl_cffi.requests.websockets.ON_CLOSE_T was removed in curl-cffi 0.17.0 [pypi.org](https://pypi.org/project/curl-cffi/0.17.0/)
- **Removed** `curl_cffi.requests.websockets.ON_DATA_T`  

curl_cffi.requests.websockets.ON_DATA_T was removed in curl-cffi 0.17.0 [pypi.org](https://pypi.org/project/curl-cffi/0.17.0/)
- **Removed** `curl_cffi.requests.websockets.ON_ERROR_T`  

curl_cffi.requests.websockets.ON_ERROR_T was removed in curl-cffi 0.17.0 [pypi.org](https://pypi.org/project/curl-cffi/0.17.0/)
- **Removed** `curl_cffi.requests.websockets.ON_MESSAGE_T`  

curl_cffi.requests.websockets.ON_MESSAGE_T was removed in curl-cffi 0.17.0 [pypi.org](https://pypi.org/project/curl-cffi/0.17.0/)
- **Removed** `curl_cffi.requests.websockets.ON_OPEN_T`  

curl_cffi.requests.websockets.ON_OPEN_T was removed in curl-cffi 0.17.0 [pypi.org](https://pypi.org/project/curl-cffi/0.17.0/)
- **Removed** `curl_cffi.requests.websockets.RECV_QUEUE_ITEM`  

curl_cffi.requests.websockets.RECV_QUEUE_ITEM was removed in curl-cffi 0.17.0 [pypi.org](https://pypi.org/project/curl-cffi/0.17.0/)
- **Removed** `curl_cffi.requests.websockets.SEND_QUEUE_ITEM`  

curl_cffi.requests.websockets.SEND_QUEUE_ITEM was removed in curl-cffi 0.17.0 [pypi.org](https://pypi.org/project/curl-cffi/0.17.0/)
- **Behavior changed** `trust_env`  

With trust_env=False, requests now ignores proxy environment variables. Code that relied on those variables being used despite trust_env=False must pass proxies explicitly. [github.com](https://github.com/lexiforest/curl%5Fcffi/releases/tag/v0.17.0)
- **Signature changed** `curl_cffi.AsyncSession.stream`  

Was async def stream(self, method: HttpMethod, url: str, \*\*kwargs: Unpack\[StreamRequestParams\]) -> AsyncGenerator\[R, None, None\]; now async def stream(self, method: HttpMethod, url: str, \*\*kwargs: Unpack\[StreamRequestParams\]) ->... [pypi.org](https://pypi.org/project/curl-cffi/0.17.0/)
- **Signature changed** `curl_cffi.AsyncWebSocket.__aenter__`  

Was async def \_\_aenter\_\_(self) -> Self; now async def \_\_aenter\_\_(self) -> AsyncWebSocket. [pypi.org](https://pypi.org/project/curl-cffi/0.17.0/)
- **Signature changed** `curl_cffi.AsyncWebSocket.__aexit__`  

Was async def \_\_aexit\_\_(self, exc_type: type\[BaseException\] | None, exc_val: BaseException | None, exc_tb: object | None) -> None; now async def \_\_aexit\_\_(self, exc_type: type\[BaseException\] | None, exc_val: BaseException | None, exc_tb... [pypi.org](https://pypi.org/project/curl-cffi/0.17.0/)
- **Signature changed** `curl_cffi.AsyncWebSocket.__aiter__`  

Was def \_\_aiter\_\_(self) -> Self; now def \_\_aiter\_\_(self) -> AsyncWebSocket. [pypi.org](https://pypi.org/project/curl-cffi/0.17.0/)
- **Signature changed** `curl_cffi.AsyncWebSocket.loop`  

Was loop: asyncio.AbstractEventLoop; now loop: AbstractEventLoop. [pypi.org](https://pypi.org/project/curl-cffi/0.17.0/)
- **Signature changed** `curl_cffi.Curl.ws_send`  

Was def ws_send(self, payload: bytes | memoryview, flags: CurlWsFlag | int = CurlWsFlag.BINARY) -> int; now def ws_send(self, payload: bytes | bytearray | memoryview, flags: CurlWsFlag | int = CurlWsFlag.BINARY) -> int. [pypi.org](https://pypi.org/project/curl-cffi/0.17.0/)
- **Signature changed** `curl_cffi.ExtraFingerprints.__init__`  

Was def \_\_init\_\_(self, tls_min_version: Optional\[int\] = None, tls_grease: Optional\[bool\] = None, tls_permute_extensions: Optional\[bool\] = None, tls_cert_compression: Optional\[Literal\['zlib', 'brotli'\]\] = None, tls_signature_algorithms... [pypi.org](https://pypi.org/project/curl-cffi/0.17.0/)
- **Signature changed** `curl_cffi.Fingerprint.__init__`  

Was def \_\_init\_\_(self, client: str = '', client_version: str = '', os: str = '', os_version: str = '', http_version: str = 'v2', tls_version: str = '1.2', tls_ciphers: list\[str\] = list(), tls_alpn: bool = False, tls_alps: bool = False... [pypi.org](https://pypi.org/project/curl-cffi/0.17.0/)
- **Signature changed** `curl_cffi.fingerprints.FingerprintSpec.__init__`  

Was def \_\_init\_\_(self, platform: str | None = None, client: ClientLiteral | None = None, strategy: Literal\['uniform'\] | None = 'uniform') -> None; now def \_\_init\_\_(self, platform: PlatformLiteral | None = None, client: ClientLiteral | None... [pypi.org](https://pypi.org/project/curl-cffi/0.17.0/)
- **Signature changed** `curl_cffi.fingerprints.FingerprintSpec.platform`  

Was platform: str | None; now platform: PlatformLiteral | None. [pypi.org](https://pypi.org/project/curl-cffi/0.17.0/)
- **Signature changed** `curl_cffi.requests.session.AsyncWebSocketContext.__aexit__`  

Was async def \_\_aexit\_\_(self, exc_type: type\[BaseException\] | None, exc: BaseException | None, tb: object | None) -> None; now async def \_\_aexit\_\_(self, exc_type: type\[BaseException\] | None, exc: BaseException | None, tb: TracebackType |... [pypi.org](https://pypi.org/project/curl-cffi/0.17.0/)
- **Signature changed** `curl_cffi.requests.session.BaseSession.__init__`  

Was def \_\_init\_\_(self, \*, headers: Optional\[HeaderTypes\] = None, cookies: Optional\[CookieTypes\] = None, auth: Optional\[tuple\[str, str\]\] = None, proxies: Optional\[ProxySpec\] = None, proxy: Optional\[str\] = None, proxy_auth... [pypi.org](https://pypi.org/project/curl-cffi/0.17.0/)
- **Signature changed** `curl_cffi.requests.session.set_curl_options`  

Was def set_curl_options(curl: Curl, method: HttpMethod, url: str, \*, params_list: list\[Union\[dict\[str, object\], list\[object\], tuple\[object, ...\], None\]\] = \[\], base_url: Optional\[str\] = None, data: Optional\[RequestData\] = None, content... [pypi.org](https://pypi.org/project/curl-cffi/0.17.0/)
- **Signature changed** `curl_cffi.requests.utils.set_curl_options`  

Was def set_curl_options(curl: Curl, method: HttpMethod, url: str, \*, params_list: list\[Union\[dict\[str, object\], list\[object\], tuple\[object, ...\], None\]\] = \[\], base_url: Optional\[str\] = None, data: Optional\[RequestData\] = None, content... [pypi.org](https://pypi.org/project/curl-cffi/0.17.0/)
- **Signature changed** `curl_cffi.requests.websockets.BaseWebSocket.__init__`  

Was def \_\_init\_\_(self, curl: Curl | NotSetType, \*, autoclose: bool = True, debug: bool = False) -> None; now def \_\_init\_\_(self, curl: Curl | NotSetType = NOT_SET, \*, autoclose: bool = True, skip_utf8_validation: bool = False, debug: bool =... [pypi.org](https://pypi.org/project/curl-cffi/0.17.0/)
- **Signature changed** `curl_cffi.requests.websockets.set_curl_options`  

Was def set_curl_options(curl: Curl, method: HttpMethod, url: str, \*, params_list: list\[Union\[dict\[str, object\], list\[object\], tuple\[object, ...\], None\]\] = \[\], base_url: Optional\[str\] = None, data: Optional\[RequestData\] = None, content... [pypi.org](https://pypi.org/project/curl-cffi/0.17.0/)
- **Signature changed** `curl_cffi.Response.json`  

Was def json(self, \*\*kw); now def json(self, \*, path: Optional\[str\] = None, default: Any = None, \*\*kw: Any) -> Any. [pypi.org](https://pypi.org/project/curl-cffi/0.17.0/)
- **Signature changed** `curl_cffi.Session.__init__`  

Was def \_\_init\_\_(self, curl: Optional\[Curl\] = None, thread: Optional\[ThreadType\] = None, use_thread_local_curl: bool = True, \*\*kwargs: Unpack\[BaseSessionParams\[R\]\]) -> None; now def \_\_init\_\_(self, curl: Optional\[Curl\] = None, thread... [pypi.org](https://pypi.org/project/curl-cffi/0.17.0/)
- **Signature changed** `curl_cffi.Session.request`  

Was def request(self, method: HttpMethod, url: str, params: Optional\[Union\[dict, list, tuple\]\] = None, data: Optional\[RequestData\] = None, content: Optional\[SyncRequestContent\] = None, json: Optional\[dict | list\] = None, headers... [pypi.org](https://pypi.org/project/curl-cffi/0.17.0/)
- **Signature changed** `curl_cffi.Session.ws_connect`  

Was def ws_connect(self, url: str, on_message=None, on_error=None, on_open=None, on_close=None, \*\*kwargs) -> WebSocket; now def ws_connect(self, url: str, on_message: Callable\[\[WebSocket, bytes | str\], None\] | None = None, on_error... [pypi.org](https://pypi.org/project/curl-cffi/0.17.0/)
- **Signature changed** `curl_cffi.WebSocket.__init__`  

Was def \_\_init\_\_(self, curl: Curl | NotSetType = NOT_SET, \*, autoclose: bool = True, skip_utf8_validation: bool = False, debug: bool = False, on_open: ON_OPEN_T | None = None, on_close: ON_CLOSE_T | None = None, on_data: ON_DATA_T | None =... [pypi.org](https://pypi.org/project/curl-cffi/0.17.0/)
- **Signature changed** `curl_cffi.WebSocket.close`  

Was def close(self, code: int = WsCloseCode.OK, message: bytes = b''); now def close(self, code: int | WsCloseCode = WsCloseCode.OK, message: str | bytes = b'', timeout: float = 3.0) -> None. [pypi.org](https://pypi.org/project/curl-cffi/0.17.0/)
- **Signature changed** `curl_cffi.WebSocket.connect`  

Was def connect(self, url: str, params: dict\[str, object\] | list\[object\] | tuple\[str, int | list\[str\] | dict\[str, str | int\]\] | None = None, headers: HeaderTypes | None = None, cookies: CookieTypes | None = None, auth: tuple\[str, str\] |... [pypi.org](https://pypi.org/project/curl-cffi/0.17.0/)
- **Signature changed** `curl_cffi.WebSocket.ping`  

Was def ping(self, payload: str | bytes) -> int; now def ping(self, payload: str | bytes = b'', \*, timeout: float | None = None) -> int. [pypi.org](https://pypi.org/project/curl-cffi/0.17.0/)
- **Signature changed** `curl_cffi.WebSocket.recv`  

Was def recv(self) -> tuple\[bytes, int\]; now def recv(self, \*, timeout: float | None = None) -> tuple\[bytes, int\]. [pypi.org](https://pypi.org/project/curl-cffi/0.17.0/)
- **Signature changed** `curl_cffi.WebSocket.recv_json`  

Was def recv_json(self, \*, loads: Callable\[\[str\], T\] = json_loads) -> T; now def recv_json(self, \*, loads: Callable\[\[str\], T\] = json_loads, timeout: float | None = None) -> T. [pypi.org](https://pypi.org/project/curl-cffi/0.17.0/)
- **Signature changed** `curl_cffi.WebSocket.recv_str`  

Was def recv_str(self) -> str; now def recv_str(self, \*, timeout: float | None = None) -> str. [pypi.org](https://pypi.org/project/curl-cffi/0.17.0/)
- **Signature changed** `curl_cffi.WebSocket.send`  

Was def send(self, payload: str | bytes, flags: CurlWsFlag = CurlWsFlag.BINARY) -> int; now def send(self, payload: str | bytes | bytearray | memoryview, flags: CurlWsFlag | int = CurlWsFlag.BINARY, \*, timeout: float | None = None) -> int. [pypi.org](https://pypi.org/project/curl-cffi/0.17.0/)
- **Signature changed** `curl_cffi.WebSocket.send_binary`  

Was def send_binary(self, payload: bytes) -> int; now def send_binary(self, payload: bytes | bytearray | memoryview, \*, timeout: float | None = None) -> int. [pypi.org](https://pypi.org/project/curl-cffi/0.17.0/)
- **Signature changed** `curl_cffi.WebSocket.send_bytes`  

Was def send_bytes(self, payload: bytes); now def send_bytes(self, payload: bytes | bytearray | memoryview, \*, timeout: float | None = None) -> int. [pypi.org](https://pypi.org/project/curl-cffi/0.17.0/)
- **Signature changed** `curl_cffi.WebSocket.send_json`  

Was def send_json(self, payload: object, \*, dumps: Callable\[..., str\] = json_dumps) -> int; now def send_json(self, payload: object, \*, dumps: Callable\[..., str | bytes\] = json_dumps, timeout: float | None = None) -> int. [pypi.org](https://pypi.org/project/curl-cffi/0.17.0/)
- **Signature changed** `curl_cffi.WebSocket.send_str`  

Was def send_str(self, payload: str) -> int; now def send_str(self, payload: str, \*, timeout: float | None = None) -> int. [pypi.org](https://pypi.org/project/curl-cffi/0.17.0/)
- **Signature changed** `curl_cffi.WebSocketError.__init__`  

Was def \_\_init\_\_(self, message: str, code: WsCloseCode | CurlECode | Literal\[0\] = 0) -> None; now def \_\_init\_\_(self, message: str, code: WsCloseCode | CurlECode | int = 0) -> None. [pypi.org](https://pypi.org/project/curl-cffi/0.17.0/)

## curl-cffi 0.16.0 breaking changes

curl-cffi 0.16.0, released August 1, 2026: 42 breaking changes.

- **Removed** `curl_cffi.is_pro`  

curl_cffi.is_pro was removed in curl-cffi 0.16.0 [pypi.org](https://pypi.org/project/curl-cffi/0.16.0/)
- **Removed** `curl_cffi.requests.impersonate.CurlCffiWarning`  

curl_cffi.requests.impersonate.CurlCffiWarning was removed in curl-cffi 0.16.0 [pypi.org](https://pypi.org/project/curl-cffi/0.16.0/)
- **Removed** `curl_cffi.requests.impersonate.CurlOpt`  

curl_cffi.requests.impersonate.CurlOpt was removed in curl-cffi 0.16.0 [pypi.org](https://pypi.org/project/curl-cffi/0.16.0/)
- **Removed** `curl_cffi.requests.impersonate.toggle_extension`  

curl_cffi.requests.impersonate.toggle_extension was removed in curl-cffi 0.16.0 [pypi.org](https://pypi.org/project/curl-cffi/0.16.0/)
- **Removed** `curl_cffi.requests.models.clear_queue`  

curl_cffi.requests.models.clear_queue was removed in curl-cffi 0.16.0 [pypi.org](https://pypi.org/project/curl-cffi/0.16.0/)
- **Removed** `curl_cffi.requests.session.CurlMorsel`  

curl_cffi.requests.session.CurlMorsel was removed in curl-cffi 0.16.0 [pypi.org](https://pypi.org/project/curl-cffi/0.16.0/)
- **Removed** `curl_cffi.requests.websockets.dumps_partial`  

curl_cffi.requests.websockets.dumps_partial was removed in curl-cffi 0.16.0 [pypi.org](https://pypi.org/project/curl-cffi/0.16.0/)
- **Renamed** `curl_cffi.requests.impersonate.normalize_browser_type`  

Use curl_cffi.requests.impersonate.resolve_latest_browser_type instead. [pypi.org](https://pypi.org/project/curl-cffi/0.16.0/)
- **Behavior changed**  

Errors raised inside callbacks are now propagated to the caller instead of being swallowed, which can change how existing callback code behaves. [github.com](https://github.com/lexiforest/curl%5Fcffi/releases/tag/v0.16.0)
- **Behavior changed**  

The bundled libcurl moved to 8.21 with curl-impersonate 2.0, which may change low-level HTTP/TLS behavior for existing code. [github.com](https://github.com/lexiforest/curl%5Fcffi/releases/tag/v0.16.0)

And 32 more in this version. [Sign up to see every change](https://app.since.dev/login?mode=signup&src=package-page)

## curl-cffi 0.15.0 breaking changes

curl-cffi 0.15.0, released April 3, 2026: 88 breaking changes.

- **Removed** `curl_cffi.AsyncWebSocket.__del__`  

AsyncWebSocket.\_\_del\_\_ was removed in curl-cffi 0.15.0 [pypi.org](https://pypi.org/project/curl-cffi/0.15.0/)
- **Removed** `curl_cffi.AsyncWebSocket.retry_on_recv_error`  

AsyncWebSocket.retry_on_recv_error was removed in curl-cffi 0.15.0 [pypi.org](https://pypi.org/project/curl-cffi/0.15.0/)
- **Removed** `curl_cffi.cli.curl_cffi`  

curl_cffi.cli.curl_cffi was removed in curl-cffi 0.15.0 [pypi.org](https://pypi.org/project/curl-cffi/0.15.0/)
- **Removed** `curl_cffi.const.CurlECode.RESERVED115115`  

curl_cffi.const.CurlECode.RESERVED115115 was removed in curl-cffi 0.15.0 [pypi.org](https://pypi.org/project/curl-cffi/0.15.0/)
- **Removed** `curl_cffi.const.CurlECode.RESERVED116116`  

curl_cffi.const.CurlECode.RESERVED116116 was removed in curl-cffi 0.15.0 [pypi.org](https://pypi.org/project/curl-cffi/0.15.0/)
- **Removed** `curl_cffi.const.CurlECode.RESERVED117117`  

curl_cffi.const.CurlECode.RESERVED117117 was removed in curl-cffi 0.15.0 [pypi.org](https://pypi.org/project/curl-cffi/0.15.0/)
- **Removed** `curl_cffi.const.CurlECode.RESERVED118118`  

curl_cffi.const.CurlECode.RESERVED118118 was removed in curl-cffi 0.15.0 [pypi.org](https://pypi.org/project/curl-cffi/0.15.0/)
- **Removed** `curl_cffi.const.CurlECode.RESERVED119119`  

curl_cffi.const.CurlECode.RESERVED119119 was removed in curl-cffi 0.15.0 [pypi.org](https://pypi.org/project/curl-cffi/0.15.0/)
- **Removed** `curl_cffi.const.CurlECode.RESERVED120120`  

curl_cffi.const.CurlECode.RESERVED120120 was removed in curl-cffi 0.15.0 [pypi.org](https://pypi.org/project/curl-cffi/0.15.0/)
- **Removed** `curl_cffi.const.CurlECode.RESERVED121121`  

curl_cffi.const.CurlECode.RESERVED121121 was removed in curl-cffi 0.15.0 [pypi.org](https://pypi.org/project/curl-cffi/0.15.0/)

And 78 more in this version. [Sign up to see every change](https://app.since.dev/login?mode=signup&src=package-page)

## Check your code

These are the changes. To see which of them reach your code, [scan a public repository](https://since.dev/scan.md), or have your coding agent call `check_code` with your manifest or lockfile over [MCP](https://since.dev/docs.md#mcp). [The API](https://since.dev/docs.md#api) reads every change in every version. A fix pull request opens for the changes that reach a connected repository. Nothing merges or deploys.

## Put your code on continuous maintenance.

Scan a public repository now, or give your agent one line.

[Scan a repository](https://since.dev/scan.md). Any public GitHub repository. No sign-in.

### Tell your agent what changed since it was trained.

`claude mcp add --transport http since https://api.since.dev/mcp`

[Get an API key](https://app.since.dev/login?mode=signup)

Codex, Cursor and any MCP client use https://api.since.dev/mcp.

---

Every page on this site as Markdown: https://since.dev/sitemap.md. For agents: https://since.dev/llms.txt.
