#5452 Add pull request ID to push notification payload
Merged by ngompa. Opened by nforro.
nforro/pagure pr_id  into  master

Download 5452.patch

Packit now consumes org.fedoraproject.prod.pagure.git.receive fedmsg messages, but unlike previously used org.fedoraproject.prod.git.receive there is no indication whether a push is a result of a pull request merge. It turns out there is no reliable way to get that information and to find the matching pull request. We could start consuming also org.fedoraproject.prod.pagure.pull-request.closed messages but we would still need to exclude related org.fedoraproject.prod.pagure.git.receive messages (as a PR merge generates both) and that would be prone to race conditions, so adding ID of a pull request whose merge triggered the event directly to org.fedoraproject.prod.pagure.git.receive payload seems like a better solution.

Doesn't this require extending pagure-messages first?

Doesn't this require extending pagure-messages first?

Oh, I wasn't aware of that, thanks for the pointer! So I suppose GitReceiveV1 schema should have been modified as well before #5435 was merged (yet somehow it works). Let me fix it.

I've opened pagure-messages PR: https://pagure.io/pagure-messages/pull-request/15

rebased onto 8ed510d99c9fbe3736c96b751d567891cbad343a

Pull-Request has been merged by ngompa

Metadata