imalplibutil calls strptime with string

datetime.datetime.strptime wants a string object,
but we have a bytes object. We need decode it.
This commit is contained in:
Rodolfo García Peñas (kix) 2020-08-31 18:08:55 +02:00
parent d011702b5b
commit b6cec81090

View File

@ -249,7 +249,7 @@ def Internaldate2epoch(resp):
return None
# Get the month number
datetime_object = datetime.datetime.strptime(mo.group('mon'), "%b")
datetime_object = datetime.datetime.strptime(mo.group('mon').decode('utf-8'), "%b")
mon = datetime_object.month
zonen = mo.group('zonen')