def set(self, key, value, preserve=False, getset=False):
        if preserve:
            warnings.warn(DeprecationWarning(
                "preserve option to 'set' is deprecated, "
                "use redis.setnx() instead"))
            return self.setnx(key, value)

        if getset:
            warnings.warn(DeprecationWarning(
                "getset option to 'set' is deprecated, "
                "use redis.getset() instead"))
            return self.getset(key, value)

        return self.execute_command("SET", key, value)
Set a key to a string value
dataset/ETHPy150Open jookies/jasmin/jasmin/vendor/txredisapi.py/RedisProtocol.set