def create_trails(self, trail_ids):
        trails = []
        for x in trail_ids:
            url_search = self.es.search(index=self.index, q=x % "trail_id:%d",
                fields="url", size=1000)["hits"]["hits"]
            new_trail = {"trail_id": x, "urls": [], "domain_name":url_search[0]["_type"]}
            for y in url_search:
                new_trail["urls"].append(y["fields"]["url"][0])
            new_trail.update({"urls_string": "\n".join(new_trail["urls"])})
            trails.append(new_trail)
        return trails
dataset/ETHPy150Open memex-explorer/memex-explorer/source/memex/rest.py/DataWakeView.create_trails/swapped operands of `%`