docs: def load_manifest_file(client, bucket, schema, versioned, ifilters, key_info):
      """Given an inventory csv file, return an iterator over keys
      """
      # To avoid thundering herd downloads, we do an immediate yield for
      # interspersed i/o
      yield None
  
      # Inline these values to avoid the local var lookup, they are constants
      # rKey = schema['Key'] # 1
      # rIsLatest = schema['IsLatest'] # 3
      # rVersionId = schema['VersionId'] # 2
  
      with tempfile.NamedTemporaryFile() as fh:
          client.download_fileobj(Bucket=bucket, Key=key_info['key'], Fileobj=fh)
          fh.seek(0)
          reader = csv.reader(gzip.GzipFile(fileobj=fh, mode='r'))
          for key_set in chunks(reader, 1000):
              keys = []
              for kr in key_set:
                  k = kr[1]
                  if inventory_filter(ifilters, schema, kr):
                      continue
                  k = unquote_plus(k)
                  if versioned:
                      if kr[3] == 'true':
                          keys.append((k, kr[2], True))
                      else:
                          keys.append((k, kr[2]))
                  else:
                      keys.append(k)
              yield keys