Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 7b33457

Browse files
committed
refactor: some leftover pyupgrade 3.10 bits
1 parent 2ff968d commit 7b33457

2 files changed

Lines changed: 3 additions & 3 deletions

File tree

coverage/misc.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -167,10 +167,10 @@ def update(self, v: Any) -> None:
167167
case None:
168168
pass
169169
case str():
170-
self.hash.update(f"{len(v)}:".encode("utf-8"))
170+
self.hash.update(f"{len(v)}:".encode())
171171
self.hash.update(v.encode("utf-8"))
172172
case bytes():
173-
self.hash.update(f"{len(v)}:".encode("utf-8"))
173+
self.hash.update(f"{len(v)}:".encode())
174174
self.hash.update(v)
175175
case int() | float():
176176
self.hash.update(str(v).encode("utf-8"))

tests/strategies.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55

66
from __future__ import annotations
77

8-
from typing import Sequence
8+
from collections.abc import Sequence
99

1010
from hypothesis import strategies as st
1111

0 commit comments

Comments
 (0)