

def set_hash_key(self, file):
    'Calculate and store hash key for file.'
    filehasher = hashlib.md5()
    while True:
        data = file.read(8192)
        if (not data):
            break
        filehasher.update(data)
    self.seek(0)
    self.hash_key = filehasher.hexdigest()

dataset/ETHPy150Open jcushman/pdfquery/pdfquery/cache.py BaseCache.set_hash_key/VarMisuse@55/78 `file`->`self`