Skip to content

Commit

Permalink
Merge pull request #77 from varunvarma/utf8_in_resource_cache_setup
Browse files Browse the repository at this point in the history
Decode UTF-8 when inserting resource metadata key/values into Resource Cache
  • Loading branch information
road-cycling committed Sep 25, 2019
2 parents 58f2b6d + 1b1477c commit 3a84b6b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion yahoo_panoptes/framework/resources.py
Expand Up @@ -924,7 +924,7 @@ def setup_resource_cache(self):
'''
INSERT INTO resource_metadata(id, key, value) VALUES(?,?,?)
''',
(rowid, key, resource.resource_metadata[key])
(rowid, key.decode('utf-8'), resource.resource_metadata[key].decode('utf-8'))
)
self._db.commit()
# Invalidate cached resources
Expand Down

0 comments on commit 3a84b6b

Please sign in to comment.