When some patch gets abandoned the Patch-For-Review tag gets removed by @Maintenance_bot. When this patch now gets restored, @gerritbot doesn't add the Patch-For-Review tag back to the task. (e.g. T267447)
Description
Details
Related Objects
- Mentioned Here
- T267447: Hard deprecate BaseTemplate::getFooterIcons
Event Timeline
The implementation is the Gerrit plugin its-phabricator. The doc is at https://gerrit.wikimedia.org/r/plugins/its-phabricator/Documentation/index.html
The rules are defined in operations/puppet.git:
[rule "patchSetAbandoned"] event-type = change-abandoned association = subject,footer-Bug,footer-bug action = add-soy-comment PatchSetAbandoned [rule "patchSetRestored"] event-type = change-restored association = subject,footer-Bug,footer-bug action = add-soy-comment PatchSetRestored [rule "patchSetMerged"] event-type = change-merged association = subject,footer-Bug,footer-bug action = add-soy-comment PatchSetMerged [rule "patchSetCreated"] event-type = patchset-created association = added@subject,added@footer-Bug,added@footer-bug action = add-soy-comment PatchSetCreated action = add-project Patch-For-Review # <--------------------- add the project on patchset creation
The Gerrit plugin does trigger when a patch is restored:
To add the project the actions are defined at https://gerrit.wikimedia.org/r/plugins/its-phabricator/Documentation/config-rulebase-plugin-actions.md
So we just have to add the add-project Patch-For-Review action in the patchSetRestored rule.
Change 674548 had a related patch set uploaded (by Hashar; owner: Hashar):
[operations/puppet@production] gerrit: restoring a change adds Patch-For-Review
Change 674548 merged by Dzahn:
[operations/puppet@production] gerrit: restoring a change adds Patch-For-Review
Change 675091 had a related patch set uploaded (by Hashar; author: Hashar):
[test/gerrit-ping@master] its-pharbricator adds Patch-For-Review on restore
Change 675091 abandoned by Hashar:
[test/gerrit-ping@master] its-pharbricator adds Patch-For-Review on restore
Reason:
Change 675091 restored by Hashar:
[test/gerrit-ping@master] its-pharbricator adds Patch-For-Review on restore
Change 675091 abandoned by Hashar:
[test/gerrit-ping@master] its-pharbricator adds Patch-For-Review on restore
Reason:
it worked