Change .now() to .utcnow() (#22233)
ephem works in UTC time, not local time. As a result, our comparison needs to be in UTC for accurate results.pull/22266/head
parent
72bb94de96
commit
bc85d47878
|
@ -130,5 +130,5 @@ class Season(Entity):
|
|||
|
||||
def update(self):
|
||||
"""Update season."""
|
||||
self.datetime = datetime.now()
|
||||
self.datetime = datetime.utcnow()
|
||||
self.season = get_season(self.datetime, self.hemisphere, self.type)
|
||||
|
|
Loading…
Reference in New Issue