new_variant: fix query string for Original-Change-Id

Add a "message:" prefix to the query string that searches for the
original change ID, so that gerrit knows to search in the commit
message. It used to work, but that was apparently by accident.

This is the perfect illustration of Hyrum's Law: "all observable
behaviors of your system will be depended on by somebody."

TEST=with this patch, is able to find the coreboot
upstream CL

Change-Id: Ib4922514742544518ade7db41e70ee4686b83ab9
Commit-Queue: Paul Fagerburg <>
Commit-Queue: Jack Rosenthal <>
Tested-by: Paul Fagerburg <>
Auto-Submit: Paul Fagerburg <>
Reviewed-by: Jack Rosenthal <>
diff --git a/contrib/variant/ b/contrib/variant/
index 6dcdfc7..bc1db6c 100755
--- a/contrib/variant/
+++ b/contrib/variant/
@@ -1378,7 +1378,7 @@
     # Find the CL by the Original-Change-Id
     original_change_id = status.commits[step_names.CB_VARIANT]['change_id']
     gerrit_query_args = {
-        'Original-Change-Id': original_change_id
+        'message': f'Original-Change-Id:{original_change_id}'
     cros = gerrit.GetCrosExternal()
     upstream = cros.Query(**gerrit_query_args)