how to ignore blockers on dependent/parent changes and submit

37 views
Skip to first unread message

Bhavik Bavishi

unread,
Sep 16, 2016, 2:40:58 AM9/16/16
to repo-d...@googlegroups.com
Hi,

in series of changes, in which few are dependent. we have Jenkins job to
verify each change. Now in current situation change (109) which is
depends on (108) or say (108) is parent of (109) ...

1. base change (108) failed and job has set "Code-review" -1
2. change (109) has fix and job went fine and job tries to submit the
change.

But here getting error as below ...

----------------------------------------------------------------
ssh ... gerrit review 109,1 --verified +1 --code-review +2 -s

error: The change could not be submitted because it depends on change(s)
[108], which could not be submitted because:
108: needs Code-Review; blocked by Verified;

one or more reviews failed; review output above
----------------------------------------------------------------

Is there way to tell gerrit to ignore all "Code-review" and "verified"
status of parent change (here 108) and submit together 108 and 109 ?

- Bhavik

Edwin Kempin

unread,
Sep 16, 2016, 2:51:31 AM9/16/16
to Bhavik Bavishi, Repo and Gerrit Discussion
No. But if 109 fixes 108, then just squash them together and approve and submit the one change.
 

- Bhavik

--
--
To unsubscribe, email repo-discuss+unsubscribe@googlegroups.com
More info at http://groups.google.com/group/repo-discuss?hl=en

--- You received this message because you are subscribed to the Google Groups "Repo and Gerrit Discussion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to repo-discuss+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Matthew Webber

unread,
Sep 16, 2016, 4:11:16 AM9/16/16
to Repo and Gerrit Discussion, bhavikd...@gmail.com
We normally say that every change should verify, but there are rare cases where we allow the scenario you describe.

We handle this outside Gerrit. Our developers have the option of starting a test job for change 109, and checking a "gerrit_verify_ancestors" option, which means that if 109 verifies, then all its un-submitted ancestors will get Verified+1 as well. So when the Jenkins job posts back to Gerrit, both 108 and 109 get a Verified+1 (the default is just for 109). If you look at change 108 in Gerrit, there is a comment posted by Jenkins that says "verified as part of chain 108, 109" (or something like that). Of course this requires some custom code on our part, but it's just Python.

That requires developers to not abuse the system.

Probably a better way to do it is to have separate labels, Verified, and Verefied-with-later-change, and then allow submit if either is +1. That makes explicit the basis on which the change was acceptable.

Matthew

Bhavik Bavishi

unread,
Sep 16, 2016, 5:12:36 AM9/16/16
to repo-d...@googlegroups.com
Hi Matthew,

I'm looking for exactly the same tool. Would it be possible for you to
share "gerrit_verify_ancestors" tool/script ? or reference pointer will
help a lot.
> --
> --
> To unsubscribe, email repo-discuss...@googlegroups.com
> More info at http://groups.google.com/group/repo-discuss?hl=en
>
> ---
> You received this message because you are subscribed to the Google
> Groups "Repo and Gerrit Discussion" group.
> To unsubscribe from this group and stop receiving emails from it, send
> an email to repo-discuss...@googlegroups.com
> <mailto:repo-discuss...@googlegroups.com>.
Reply all
Reply to author
Forward
0 new messages