[Starlingx-discuss] Malformed Depends-On tag can cause unexpected merge
Hi all, Please be careful when adding dependencies to your commit messages to ensure the formatting is correct. If it is not, then Gerrit/Zuul may not properly handle the dependency and allow a commit to merge before the dependency is merged. It appears that a space is mandatory after the "Depends-On:" tag. Proper formatting: Depends-On: https://review.opendev.org/XXXXXX Improper: Depends-On:https://review.opendev.org/XXXXXX We saw updates merge this morning prematurely, apparently due to a commit message that was missing this space after the Depends-On tag. As a side note, I believe the syntax of "Depends-On: CHANGE-ID" is deprecated, maybe due to the potential for CHANGE-ID matching multiple reviews. The suggested syntax is to use the Gerrit review URL. Cheers, Don. Don Penney, Developer, Wind River
On 2019-11-12 18:14:48 +0000 (+0000), Penney, Don wrote: [...]
As a side note, I believe the syntax of "Depends-On: CHANGE-ID" is deprecated, maybe due to the potential for CHANGE-ID matching multiple reviews. The suggested syntax is to use the Gerrit review URL.
The reason using the Change-Id for Depends-On is deprecated is that Zuul v3 added the ability to have multiple connections to different code review systems, so a raw Change-Id is insufficient for locating the review if it's accessed through a different connection. GitHub doesn't even have anything analogous to Gerrit's Change-Id, so Zuul needed to adopt a more generic solution to support it anyway. -- Jeremy Stanley
Is it possible to add a zuul check to look for this malformed tag ? and also warn the committer about use of deprecated tags? Dariush From: Penney, Don [mailto:Don.Penney@windriver.com] Sent: November-12-19 1:15 PM To: 'starlingx-discuss@lists.starlingx.io' (starlingx-discuss@lists.starlingx.io) <starlingx-discuss@lists.starlingx.io> Subject: [Starlingx-discuss] Malformed Depends-On tag can cause unexpected merge Hi all, Please be careful when adding dependencies to your commit messages to ensure the formatting is correct. If it is not, then Gerrit/Zuul may not properly handle the dependency and allow a commit to merge before the dependency is merged. It appears that a space is mandatory after the "Depends-On:" tag. Proper formatting: Depends-On: https://review.opendev.org/XXXXXX Improper: Depends-On:https://review.opendev.org/XXXXXX We saw updates merge this morning prematurely, apparently due to a commit message that was missing this space after the Depends-On tag. As a side note, I believe the syntax of "Depends-On: CHANGE-ID" is deprecated, maybe due to the potential for CHANGE-ID matching multiple reviews. The suggested syntax is to use the Gerrit review URL. Cheers, Don. Don Penney, Developer, Wind River
On 2019-11-12 18:41:59 +0000 (+0000), Eslimi, Dariush wrote:
Is it possible to add a zuul check to look for this malformed tag ? and also warn the committer about use of deprecated tags? [...]
You could add some sort of job to look for the mistyped version with the missing space, I suppose, but that wouldn't catch the myriad of other ways you could also mistype it. Another common example is folks using review.openstack.org instead of review.opendev.org in the hyperlink text (this will similarly cause it not to be used), but you could just as easily type Depend-On without the "s" or forget the ":" or use "_" instead of "-" or any of a number of other possibilities. There is no substitute for attention to detail. -- Jeremy Stanley
I agree that there are no substitutes for attention to detail, but space is easy to overlook and has happened more than once. Dariush -----Original Message----- From: Jeremy Stanley [mailto:fungi@yuggoth.org] Sent: November-12-19 1:50 PM To: starlingx-discuss@lists.starlingx.io Subject: Re: [Starlingx-discuss] Malformed Depends-On tag can cause unexpected merge On 2019-11-12 18:41:59 +0000 (+0000), Eslimi, Dariush wrote:
Is it possible to add a zuul check to look for this malformed tag ? and also warn the committer about use of deprecated tags? [...]
You could add some sort of job to look for the mistyped version with the missing space, I suppose, but that wouldn't catch the myriad of other ways you could also mistype it. Another common example is folks using review.openstack.org instead of review.opendev.org in the hyperlink text (this will similarly cause it not to be used), but you could just as easily type Depend-On without the "s" or forget the ":" or use "_" instead of "-" or any of a number of other possibilities. There is no substitute for attention to detail. -- Jeremy Stanley
participants (3)
-
Eslimi, Dariush
-
Jeremy Stanley
-
Penney, Don