diff options
-rw-r--r-- | crocoite/logger.py | 4 | ||||
-rw-r--r-- | setup.py | 1 |
2 files changed, 4 insertions, 1 deletions
diff --git a/crocoite/logger.py b/crocoite/logger.py index e8ff594..1a269b1 100644 --- a/crocoite/logger.py +++ b/crocoite/logger.py @@ -32,6 +32,8 @@ from datetime import datetime from functools import partial from enum import IntEnum +from pytz import utc + class Level(IntEnum): DEBUG = 0 INFO = 1 @@ -124,7 +126,7 @@ class JsonPrintConsumer (Consumer): class DatetimeConsumer (Consumer): def __call__ (self, **kwargs): - kwargs['date'] = datetime.utcnow () + kwargs['date'] = datetime.utcnow ().replace (tzinfo=utc) return kwargs class WarcHandlerConsumer (Consumer): @@ -14,6 +14,7 @@ setup( 'warcio', 'html5lib>=0.999999999', 'bottom', + 'pytz', ], entry_points={ 'console_scripts': [ |