DRONE_COMMIT_AUTHOR_NAME and DRONE_COMMIT_AUTHOR_EMAIL are not available for pull requests

Hi guys!
DRONE_COMMIT_AUTHOR_NAME and DRONE_COMMIT_AUTHOR_EMAIL are not available on pull request events using Github private repo. However, they are available on push events (for example, when PR has been merged into develop branch).
Please, could you advise if this is a known issue?
We want to notify our users via emails on PR events.

Thanks in advance.

This is expected. GitHub does not include this information in the Pull Request webhook payload [1], which means it is therefore unavailable in your build environment.

[1] sample pull request payload demonstrates author name and email are not available https://github.com/drone/go-scm/blob/master/scm/driver/github/testdata/webhooks/pr_sync.json

Many thanks for the quick reply, Brad!
Could you please advise if this feature is available, say, in GitLab?

I do not see this information available in GitLab either. Here is a sample GitLab payload for pull requests https://github.com/drone/go-scm/blob/master/scm/driver/gitlab/testdata/webhooks/pull_request_create.json

Got it! Many thanks!

If someone needs commiter’s name and email during PR, then one could get it in the following way:
- name: get-commiters-details
image: docker:git
- echo $(git show -s --format=’%ae’ DRONE_COMMIT) > .commiter_email - echo (git show -s --format=’%cN’ $DRONE_COMMIT) > .commiter_name
- pull_request

@bradrydzewski , Could you please advise what could be the easiest way to add the below step to the clone step?

echo $(git show -s --format=’%ae’ $DRONE_COMMIT) > .commiter_email
I would preserve the clone logic and extend it a bit.

you can replace the default clone logic with your own custom logic. see https://docs.drone.io/user-guide/pipeline/cloning/#custom-logic

Thank you for a quick reply! Does this mean i need to customize the clone logic for all the events (clone for a feature branch, clone for a PR merge ref with a merge, etc) if I just need to amend the triggers for the step?