Skip to content

Commit fcf0546

Browse files
LVivonaacul71
authored andcommitted
style: enforce consistent import block
1 parent 85bad2d commit fcf0546

File tree

1 file changed

+3
-6
lines changed

1 file changed

+3
-6
lines changed

libp2p/peer/id.py

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,9 @@
1+
import functools
12
import hashlib
23

34
import base58
45
import multihash
56

6-
from functools import (
7-
cached_property,
8-
)
9-
107
from libp2p.crypto.keys import (
118
PublicKey,
129
)
@@ -44,11 +41,11 @@ class ID:
4441
def __init__(self, peer_id_bytes: bytes) -> None:
4542
self._bytes = peer_id_bytes
4643

47-
@cached_property
44+
@functools.cached_property
4845
def xor_id(self) -> int:
4946
return int(sha256_digest(self._bytes).hex(), 16)
5047

51-
@cached_property
48+
@functools.cached_property
5249
def base58(self) -> str:
5350
return base58.b58encode(self._bytes).decode()
5451

0 commit comments

Comments
 (0)