Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
json: improve bytes handling
  • Loading branch information
sobolevn committed Oct 30, 2022
commit c056e9c0821a360bb21c158984b70711150760e1
4 changes: 2 additions & 2 deletions stdlib/json/__init__.pyi
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ def dump(
**kwds: Any,
) -> None: ...
def loads(
s: str | bytes,
s: str | bytes | bytearray,
*,
cls: type[JSONDecoder] | None = ...,
object_hook: Callable[[dict[Any, Any]], Any] | None = ...,
Expand All @@ -58,4 +58,4 @@ def load(
object_pairs_hook: Callable[[list[tuple[Any, Any]]], Any] | None = ...,
**kwds: Any,
) -> Any: ...
def detect_encoding(b: bytes) -> str: ... # undocumented
def detect_encoding(b: bytes | bytearray) -> str: ... # undocumented