diff --git a/run.py b/run.py index 840f501..3ae958e 100755 --- a/run.py +++ b/run.py @@ -1,7 +1,7 @@ #!/usr/bin/env python # coding: utf-8 -from datetime import datetime +from datetime import datetime, timezone from distutils import spawn import argparse import json @@ -219,8 +219,8 @@ def install_dependencies(): def check_for_update(): if os.path.exists(FILE_UPDATE): mtime = os.path.getmtime(FILE_UPDATE) - last = datetime.utcfromtimestamp(mtime).strftime('%Y-%m-%d') - today = datetime.utcnow().strftime('%Y-%m-%d') + last = datetime.fromtimestamp(mtime, tz=timezone.utc).strftime('%Y-%m-%d') + today = datetime.now(timezone.utc).strftime('%Y-%m-%d') if last == today: return try: