diff options
author | Yves Fischer <yvesf-git@xapek.org> | 2014-12-11 00:31:52 +0100 |
---|---|---|
committer | Yves Fischer <yvesf-git@xapek.org> | 2014-12-11 00:31:52 +0100 |
commit | 41459cfc468b4d3046f12024586ca7a5c45a693b (patch) | |
tree | f5b299cca064297a7a274638e0b54a5f5c65f07d | |
parent | b11630e1afc7ef2350756b466a768d005eace03c (diff) | |
download | scripts-41459cfc468b4d3046f12024586ca7a5c45a693b.tar.gz scripts-41459cfc468b4d3046f12024586ca7a5c45a693b.zip |
p3
-rwxr-xr-x | imdb-lookup/imdbinfo.py | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/imdb-lookup/imdbinfo.py b/imdb-lookup/imdbinfo.py index 1fe9aa7..096475f 100755 --- a/imdb-lookup/imdbinfo.py +++ b/imdb-lookup/imdbinfo.py @@ -9,7 +9,6 @@ import dbm import json import time import base64 -import md5 import argparse import math import logging @@ -112,7 +111,7 @@ class TMDBCache(object): def poster(self, poster_path, f="w185"): self.logger.debug("poster %s", poster_path) - key = "poster_{}_{}".format(f, md5.md5(poster_path).hexdigest()[0:10]) + key = "poster_{}_{}".format(f, hashlib.md5(poster_path.encode('utf-8')).hexdigest()[0:10]) keyContentType = "{}_ct".format(key) url = "http://image.tmdb.org/t/p/{}/{}".format(f, poster_path) if key not in self.db_images: |