code: def hash_of_file(path):
      
      with open(path, 'rb') as archive:
          sha = sha256()
          while True:
              data = archive.read(2 ** 20)
              if not data:
                  break
              sha.update(data)
      return encoded_hash(sha)
docs: Return the hash of a downloaded file.