'Replace a precomputed query with a new set of things.
The query index will be updated. If a TTL is specified, it will be
applied to all columns generated by this action allowing old
precomputed queries to fall away after they\'re no longer useful.'

def replace(self, query, things, ttl=None):

    assert query.is_precomputed
    if isinstance(ttl, datetime.timedelta):
        ttl = ttl.total_seconds()
    query._replace(self.mutator, things, ttl)
