def _store():
    for (key, obj) in key_objs:
        if is_stringish(obj):
            with NamedTemporaryFile(dir=self._tmpdir, delete=False, mode='wb', prefix='metaflow.s3.put_many.') as tmp:
                tmp.write(to_bytes(obj))
                tmp.close()
                (yield (tmp.name, self._url(key), key))
        else:
            raise MetaflowS3InvalidObject(("Object corresponding to the key '%s' is not a string or a bytes object." % key))
def _store():
    for (key, obj) in key_objs:
        if is_stringish(obj):
            with NamedTemporaryFile(dir=self._tmpdir, delete=False, mode='wb', prefix='metaflow.s3.put_many.') as tmp:
                tmp.write(to_bytes(obj))
                tmp.close()
                (yield (tmp.name, self._url(key), key))
        else:
            raise MetaflowS3InvalidObject(("Object corresponding to the key '%s' is not a string or a bytes object." % key))