code: def query(self, event, pk, ts=None):
          
          key = self._keygen(event, ts)
          pk_ts = self.r.zscore(key, pk)
          return int(pk_ts) if pk_ts else None
docs: Query the last update timestamp of an event pk.
  
          You can pass a timestamp to only look for events later than that
          within the same namespace.
  
          :param event: the event name.
          :param pk: the pk value for query.
          :param ts: query event pk after ts, default to None which will query
           all span of current namespace.