From 442fb23b18ed7d641532be8dd6e5324ec735b902 Mon Sep 17 00:00:00 2001 From: Andriy Zasypkin Date: Sun, 24 Sep 2017 07:52:59 -0400 Subject: [PATCH] python3 compatibility --- cps/cache_buster.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cps/cache_buster.py b/cps/cache_buster.py index 0b0b15fb..31c98c79 100644 --- a/cps/cache_buster.py +++ b/cps/cache_buster.py @@ -24,7 +24,7 @@ def init_cache_busting(app): for filename in filenames: # compute version component rooted_filename = os.path.join(dirpath, filename) - with open(rooted_filename, 'r') as f: + with open(rooted_filename, 'rb') as f: file_hash = hashlib.md5(f.read()).hexdigest()[:7] # save version to tables