Skip to content

Commit 17743fe

Browse files
committed
Updates for tests
1 parent 714b0cb commit 17743fe

File tree

1 file changed

+6
-5
lines changed

1 file changed

+6
-5
lines changed

key-value/key-value-shared/src/key_value/shared/utils/managed_entry.py

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
from typing_extensions import Self
88

99
from key_value.shared.errors import DeserializationError, SerializationError
10-
from key_value.shared.utils.time_to_live import now, prepare_ttl, seconds_to, try_parse_datetime_str
10+
from key_value.shared.utils.time_to_live import now, seconds_to, try_parse_datetime_str
1111

1212

1313
@dataclass(kw_only=True)
@@ -82,7 +82,11 @@ def to_json(
8282

8383
@classmethod
8484
def from_dict( # noqa: PLR0912
85-
cls, data: dict[str, Any], includes_metadata: bool = True, ttl: SupportsFloat | None = None, stringified_value: bool = False
85+
cls,
86+
data: dict[str, Any],
87+
includes_metadata: bool = True,
88+
ttl: SupportsFloat | None = None,
89+
stringified_value: bool = False,
8690
) -> Self:
8791
if not includes_metadata:
8892
return cls(
@@ -127,12 +131,9 @@ def from_dict( # noqa: PLR0912
127131
raise DeserializationError(msg)
128132
value = verify_dict(obj=raw_value)
129133

130-
ttl_seconds: float | None = prepare_ttl(t=ttl)
131-
132134
return cls(
133135
created_at=created_at,
134136
expires_at=expires_at,
135-
ttl=ttl_seconds,
136137
value=value,
137138
)
138139

0 commit comments

Comments
 (0)