code: def extract_from_zip(path, candidates):
      
      temp_dir = tempfile.mkdtemp()
      with zipfile.ZipFile(path) as archive:
          archive.extractall(temp_dir)
      return [f for f in collect_files(temp_dir)
              if os.path.basename(f) in candidates]
docs: Given a zip archive and a function to detect the presence of a given
      filename, unzip the archive into a temporary directory and return the
      full path of the file. Raise an IOError if the file cannot be found
      within the archive.
  
      :param path: pathname of the archive
      :param candidates: list of names to search for