def expireat ( self , key , when ) : expire_time = datetime . fromtimestamp ( when ) key = self . _encode ( key ) if key in self . redis : self . timeouts [ key ] = expire_time return True return False
python redis hmset expire
Emulate expireat
def expireat(self, key, when):
        """Emulate expireat"""
        expire_time = datetime.fromtimestamp(when)
        key = self._encode(key)
        if key in self.redis:
            self.timeouts[key] = expire_time
            return True
        return False