From bbfa96d4ef7f3a8595c9eca84caa2cdd3cd2bffc Mon Sep 17 00:00:00 2001 From: Mike McLean Date: Jan 04 2019 22:58:51 +0000 Subject: fix arches handling in listHosts --- diff --git a/hub/kojihub.py b/hub/kojihub.py index 30a9ca8..bc2b050 100644 --- a/hub/kojihub.py +++ b/hub/kojihub.py @@ -10685,8 +10685,8 @@ class RootExports(object): # matching 'ppc64' if not (isinstance(arches, list) or isinstance(arches, tuple)): arches = [arches] - archClause = [r"""arches ~ E'\\m%s\\M'""" % arch for arch in arches] - clauses.append('(' + ' OR '.join(archClause) + ')') + archPattern = r'\m(%s)\M' % '|'.join(arches) + clauses.append('arches ~ %(archPattern)s') if channelID is not None: channelID = get_channel_id(channelID, strict=True) joins.append('host_channels on host.id = host_channels.host_id')