Skip to content
Open
Show file tree
Hide file tree
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
3 changes: 1 addition & 2 deletions pysmappee/api.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@
import datetime as dt
import functools
import numbers
import pytz
import requests
from cachetools import TTLCache
from requests.exceptions import HTTPError, ConnectTimeout, ReadTimeout, \
Expand Down Expand Up @@ -211,7 +210,7 @@ def get_actuator_connection_state(self, service_location_id, actuator_id):
def _to_milliseconds(self, time):
if isinstance(time, dt.datetime):
if time.tzinfo is None:
time = time.replace(tzinfo=pytz.UTC)
time = time.replace(tzinfo=dt.timezone.utc)
return int(time.timestamp() * 1e3)
elif isinstance(time, numbers.Number):
return time
Expand Down
1 change: 0 additions & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@
install_requires=[
"cachetools>=4.0.0",
"paho-mqtt>=1.5.0",
"pytz>=2019.3",
"requests>=2.23.0",
"requests-oauthlib>=1.3.0",
"schedule>=1.1.0",
Expand Down