Skip to content

Commit 90aff92

Browse files
LaunchDarklyReleaseBotrobertjnealLaunchDarklyCIeli-darklybwoskow-ld
authored
prepare 8.2.1 release (#229)
## [8.2.1] - 2023-10-20 ### Fixed: - Replace deprecated `utcfromtimestamp` usage. --------- Co-authored-by: Robert J. Neal <rneal@launchdarkly.com> Co-authored-by: Robert J. Neal <robertjneal@users.noreply.github.com> Co-authored-by: LaunchDarklyCI <dev@launchdarkly.com> Co-authored-by: Eli Bishop <eli@launchdarkly.com> Co-authored-by: Ben Woskow <48036130+bwoskow-ld@users.noreply.github.com> Co-authored-by: Ember Stevens <ember.stevens@launchdarkly.com> Co-authored-by: ember-stevens <79482775+ember-stevens@users.noreply.github.com> Co-authored-by: Matthew M. Keeler <keelerm84@gmail.com> Co-authored-by: charukiewicz <charukiewicz@protonmail.com> Co-authored-by: LaunchDarklyReleaseBot <launchdarklyreleasebot@launchdarkly.com> Co-authored-by: Christian Charukiewicz <christian@foxhound.systems> Co-authored-by: Matthew M. Keeler <mkeeler@launchdarkly.com> Co-authored-by: Ben Woskow <bwoskow@launchdarkly.com> Co-authored-by: Gavin Whelan <gwhelan@launchdarkly.com> Co-authored-by: Elliot <35050275+Apache-HB@users.noreply.github.com> Co-authored-by: Gabor Angeli <gabor@squareup.com> Co-authored-by: Elliot <apachehaisley@gmail.com> Co-authored-by: LaunchDarklyCI <LaunchDarklyCI@users.noreply.github.com> Co-authored-by: hroederld <hroeder@launchdarkly.com> Co-authored-by: Louis Chan <lchan@launchdarkly.com> Co-authored-by: prpnmac <95777763+prpnmac@users.noreply.github.com> Co-authored-by: Louis Chan <91093020+louis-launchdarkly@users.noreply.github.com> Co-authored-by: Daniel Fritz <dfritz@indigoag.com>
1 parent b6cfd70 commit 90aff92

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

ldclient/impl/model/value_parsing.py

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,16 @@
11
import re
22
from re import Pattern
33
from semver import VersionInfo
4-
from datetime import tzinfo, timedelta, datetime
4+
from datetime import tzinfo, timedelta, datetime, timezone
55
from numbers import Number
66
from typing import Any, Optional
77

88
import pyrfc3339
99

1010
_ZERO = timedelta(0)
1111

12-
# A UTC class.
1312

13+
# A UTC class.
1414
class _UTC(tzinfo):
1515
"""UTC"""
1616

@@ -23,7 +23,8 @@ def tzname(self, dt):
2323
def dst(self, dt):
2424
return _ZERO
2525

26-
_epoch = datetime.utcfromtimestamp(0).replace(tzinfo=_UTC())
26+
27+
_epoch = datetime.fromtimestamp(0, timezone.utc)
2728

2829

2930
def is_number(input: Any) -> bool:

0 commit comments

Comments
 (0)