pull request merged / closed webhook contains empty body #7392

Closed
opened 2025-11-02 07:24:43 -06:00 by GiteaMirror · 0 comments
Owner

Originally created by @jpraet on GitHub (May 27, 2021).

The body is empty in the webhook payload for pull request merged / closed events.

This is causing a problem with the redmine_merge_request_links plugin: https://github.com/tf/redmine_merge_request_links/issues/27

At first I thought that this behavior maybe was intentional, but looking at the code, I don't think it is:

c61b460038/modules/notification/mail/mail.go (L127)

The pr.Issue.Content is emptied in the e-mail notification code, and as a side-effect the issue content is also empty for notifiers that are called afterwards (indexer, webhook and action).

Such unexpected manipulations of the notification input also happens here:

c61b460038/modules/notification/mail/mail.go (L57)

c61b460038/modules/notification/mail/mail.go (L154)

Originally created by @jpraet on GitHub (May 27, 2021). The body is empty in the webhook payload for pull request merged / closed events. This is causing a problem with the redmine_merge_request_links plugin: https://github.com/tf/redmine_merge_request_links/issues/27 At first I thought that this behavior maybe was intentional, but looking at the code, I don't think it is: https://github.com/go-gitea/gitea/blob/c61b460038d461ae4df722b28fd0b9871393ea84/modules/notification/mail/mail.go#L127 The pr.Issue.Content is emptied in the e-mail notification code, and as a side-effect the issue content is also empty for notifiers that are called afterwards (indexer, webhook and action). Such unexpected manipulations of the notification input also happens here: https://github.com/go-gitea/gitea/blob/c61b460038d461ae4df722b28fd0b9871393ea84/modules/notification/mail/mail.go#L57 https://github.com/go-gitea/gitea/blob/c61b460038d461ae4df722b28fd0b9871393ea84/modules/notification/mail/mail.go#L154
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/gitea#7392