Scarletio

Latest version: v1.0.84

Safety actively analyzes 702161 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 1 of 14

1.0.84

Improvements

- Add `ContentTypeParsingError`.
- Add missing `ContentType.__eq__`, `ContentType.__hash__`.
- Add `parse_content_type(string)` replacing `ContentType(string)`.
It returns `(ContentType, None | ContentTypeParsingError)`.
- Replace `ContentType.__init__` with `ContentType.__new__`. Its now a normal constructor and does not do any parsing.
- Add `ContentType.create_empty`.

Bug fixes

- Fix `ClientResponse.get_encoding` could return non-case-folded value due to charset's output were not normalized.
- Fix `content-type` parsing incorrectly handled tokens, quoted values. Now the parsing is way more stricter.

Renames, Deprecation & Removals

- `HTTPClient`'s `params` parameters renamed to `query` to keep it in sync with `URL` implementation.
- Rename `MIMEType` to `ContentType` to better reflect what its purpose is.

1.0.83

Improvements

- Add `get_token_type_and_repr_mode_for_variable`, `add_highlighted_part_into` and `add_highlighted_parts_into`
for helping for custom highlighters.
- Add new highlight token types for styled texts:
- TOKEN_TYPE_TEXT
- TOKEN_TYPE_TEXT_NEGATIVE
- TOKEN_TYPE_TEXT_POSITIVE
- TOKEN_TYPE_TEXT_NEUTRAL
- TOKEN_TYPE_TEXT_UNKNOWN
- TOKEN_TYPE_TEXT_HIGHLIGHT
- Update a few default highlight colors.

1.0.82

Improvements

- Add missing `ClientRequest.__repr__`.

Bug fixes

- Interactive console at a few cases did not display `SyntaxError` as intended while it should have.
This was due to badly built exceptions in the compiler. Workaround has been added.
- Fix `CallableAnalyzer.get_non_reserved_positional_parameter_range` could return incorrect value if there were
parameters with default values set.
- Fix `TypeError: BaseException.__new__(AttributeError) is not safe, use AttributeError.__new__()` in
`AttributeError.__new__` on pypy3.8.13.
- Fix `URLQuery` and other url parts could apply quoting on a stacked way depending on cache order. (from 1.0.80)
- Fix `ProtocolBasket.pop_available_protocol` could remove incorrect protocol from the basket. (from 1.0.81)

1.0.81

Improvements

- Add `URL.is_host_ip`.
- `ProtocolBasket.pop_available_protocol` now always returns the protocol that is the closest to expiration.

Bug fixes

- Fix `ConnectorTCP` did not cache `HostInfoBasket`-s as intended.

1.0.80

Improvements

- Add `KeepAliveInfo`.
- Add `Connection.performed_requests`.
- Add `ProtocolBasket` to group `ConnectorBase.acquired_protocols_per_host` and
`ConnectorBase.alive_protocols_per_host` into a single `.protocols_by_host`.
- Add `Keep-Alive` header support.
- `URL` implementation has been completely rewritten changing the defaults of many properties = methods.
- Add `URL.is_host_ip_v4`.
- Add `URL.is_host_ip_v6`.
- Add `Proxy`.
- Add `proxy` parameter to `HTTPClient.__new__` and `HTTPClient._request2` methods.
- Add support for `scheme`-less urls.

Bug fixes

- Fix `RawMessage.encoding` was not cached correctly.
- Fix fatal `SSLError`-s were not propagated.
- Fix `ConnectorTcp.create_proxy_connection`.

Renames, Deprecation & Removals

- Rename `Connection.transport` to `.get_transport`.
- Rename `Connection.closed` to `.is_closed`.
- Rename `BasicAuth` to `BasicAuthorization`.
- Rename `auth` parameters & attributes to `.authorization`. Also affects the ones with the `proxy_` prefix as well.
- Rename `URL.raw_subdomain` to `URL.raw_sub_domain`.
- Rename `URL.subdomain` to `URL.sub_domain`.
- Deprecate `URL.raw_parts`.
- Deprecate `URL.raw_name`.
- Deprecate `HTTPClient.__new__` and `HTTPClient._request2`'s `proxy_auth`, `proxy_url`, `proxy_haders` parameters,
use `proxy` instead.

1.0.79

Improvements

- `ClientRequest` now supports streaming the response data through async iterating over its `.payload_stream`.
- Add `PayloadStream`.
- Add `WebsocketFrame.__eq__`.
- Add `WebsocketFrame.__repr__`.

Renames, Deprecation & Removals

- Rename `WebsocketFrame.head_1` to `.head_0`.
- Rename `WebsocketFrame.is_final` to `.final`.
- Deprecate `WebsocketFrame.rsv1`, `.rsv2`, `.rsv3`.
- Rename `ClientResponse.payload_waiter` to `.payload_stream`.

Page 1 of 14

© 2025 Safety CLI Cybersecurity Inc. All Rights Reserved.