GitHub often has performance issues if the number of review comments get to large numbers. This script collects review comments from a pull request using the GitHub API and compiles it into a markdown file. The repository and the pull request number can be configured.
pip install --user pygithub
You will need to generate a personal access token that can access private repositories. GitHub docs.
Check the "repo" option: full control of private repositories.
After that update the config.py
file locally with the token and a reference to the GithHub repository as well as the pull request.
python3 compile.py
The file [Repo-Name]-pr-[number].md
would contain the generated markdown report.
- The review comments can be added or edited and the markdown report can be regenerated.