executablebooks / github-activity

Simple markdown changelogs for GitHub repositories
https://github-activity.readthedocs.io/en/latest/
BSD 3-Clause "New" or "Revised" License
47 stars 11 forks source link

Credit multiple authors of PRs #62

Closed minrk closed 1 year ago

minrk commented 2 years ago

Description / Summary

Sometimes, PRs consist of commits from multiple authors, but github-activity only lists the user who opened the PR. It would be nice if the PR credit could include all commit authors (and possibly or optionally reviewers, as well).

Value / benefit

This would improve credit for large PRs where multiple folks have contributed. Especially multi-stage PRs like the jupyterhub RBAC one, or PRs where e.g. a maintainer re-issues a contributor's PR to finish it up.

Implementation details

I think the API doesn't readily give access to all of a PR's authors, so you'll have to request all of the commits for the PR and iterate through them to retrieve the author and/or committer. A potential detail is that not all commits map to a GitHub user (e.g. due to a misconfigured git email address). I think those can be ignored, since they will ~always be the PR author or an auto-fix bot in my experience. But it will need to be handled to avoid an error, at least.

Tasks to complete