in geonames/track.py [0:0]
def params(self):
query_terms = list(self.terms) # copy
query_terms.append(str(random.randint(1, 1000))) # avoid caching
result = {
"body": {
"query": {
"bool": {
"must": [
{"match": {"feature_class.raw": "T"}},
],
"filter": [
{"terms": {"name.raw": query_terms}},
],
}
}
},
"index": None,
}
if "cache" in self._params:
result["cache"] = self._params["cache"]
return result