Bug 1471285

Summary: Webhook triggers all changed specs even without new tito tag
Product: [Community] Copr Reporter: Elliott Sales de Andrade <quantum.analyst>
Component: backendAssignee: clime
Status: CLOSED CURRENTRELEASE QA Contact:
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: unspecifiedCC: clime, praiskup
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2017-09-01 03:53:29 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Elliott Sales de Andrade 2017-07-14 21:49:11 UTC
Description of problem:
In one commit, I modified a bunch of specs, without bumping release or anything [1]. Subsequently, I tagged two packages [2, 3]. When I pushed the tags, the webhook triggered a rebuild of _all_ packages that were changed (see [4] with all packages built ~13 hours ago).

Since the repo is configured for tito builds _without_ --test, I don't expect any of the other specs to be rebuilt, and it's a waste of resources.


Version-Release number of selected component (if applicable):
Whatever was on there 13 hours ago.

Additional info:
[1] https://gitlab.com/qulogic-rpms/dask/commit/4ab18093c349e878d8348dda6e3dae68efaf5e6a
[2] https://gitlab.com/qulogic-rpms/dask/commit/da5f2232638de1bdf19332f1a8ed6cabcbe7ab41
[3] https://gitlab.com/qulogic-rpms/dask/commit/db3e8621a9528e5492b43d00dd3f76a3f0863c0f
[4] https://copr.fedorainfracloud.org/coprs/qulogic/dask/packages/

Comment 1 Elliott Sales de Andrade 2017-07-24 05:24:30 UTC
This is made more annoying by the fact that Tag Hooks in GitLab don't seem to trigger anything. I can see in the Integrations that the hook fired and returned 200, but no builds occur. I can hit the Test button and it kicks off some builds, but since Test sends a Push hook instead, it triggers builds for everything.

Comment 2 clime 2017-07-28 06:47:45 UTC
> In one commit, I modified a bunch of specs, without bumping release or anything [1]. Subsequently, I tagged two packages [2, 3]. When I pushed the tags, the webhook triggered a rebuild of _all_ packages that were changed (see [4] with all packages built ~13 hours ago).

It also depends how you have setup event sending. You need to have sending of push events disabled if you don't want to trigger builds in COPR on normal pushes. If you only send events on tag pushes, it should work as you expect.

Comment 3 Elliott Sales de Andrade 2017-08-13 00:20:07 UTC
Disabling push events and relying on tag pushes doesn't appear to work. I just pushed an update to all packages here [1] with tags. The GitLab Integrations page shows several tag push triggers. But no builds have been triggered on the copr [2].

[1] https://gitlab.com/qulogic-rpms/geopy/
[2] https://copr.fedorainfracloud.org/coprs/qulogic/geopy/builds/

Comment 4 clime 2017-08-22 08:57:04 UTC
(In reply to Elliott Sales de Andrade from comment #3)
> Disabling push events and relying on tag pushes doesn't appear to work. I
> just pushed an update to all packages here [1] with tags. The GitLab
> Integrations page shows several tag push triggers. But no builds have been
> triggered on the copr [2].
> 
> [1] https://gitlab.com/qulogic-rpms/geopy/
> [2] https://copr.fedorainfracloud.org/coprs/qulogic/geopy/builds/

Right, this was a bug. It's fixed now in https://pagure.io/copr/copr/c/82ddfcf89375d89cd1e4a13bcdc60698bdccb553.