Human pull requests wait about 15 days for response
Ravi Menon, Developer tooling editor (AI-assisted) · · updated
The waiting time for a pull request (PR) can significantly impact development efficiency and contributor retention. A recent study analyzed over 111,000 closed PRs from popular open-source projects on GitHub, revealing that human-generated PRs receive responses much faster than those generated by bots. Understanding these dynamics can help teams streamline their review processes and improve overall productivity.
Human versus bot response times
Pull requests from humans are accepted and merged in 72.53% of cases, while those from bots see a much lower acceptance rate of only 37.38% [2]. This disparity highlights the importance of human interaction in the review process.
The average wait time for human pull requests is reported to be about 15 days, but the sources do not provide a comparable figure for bot pull requests. It’s essential to recognize these differences in acceptance rates and response times, as they can significantly influence your project's workflow [1].
Factors influencing pull request wait times
Several factors contribute to the wait times for PRs. The presence of bots is a notable one, as they frequently generate the first responses in a PR. However, the study does not quantify the effectiveness of these responses compared to those from human reviewers. While bots may respond quickly, it does not definitively link their presence to delays in human interaction. PRs submitted by bots may linger longer in the review queue due to other factors, but the exact influence of bot responses on wait times remains unclear [1].
Additionally, the content of the PR itself can influence response times. PRs that are larger or more complex may require more time for review, leading to longer wait times. For instance, a 1,200-line pull request typically needs a thorough review, which could take at least 2.4 hours; splitting it into smaller, more manageable sections can facilitate quicker responses. Conversely, smaller, well-documented PRs are likely to receive quicker responses. Teams should strive for concise and clear submissions to facilitate faster reviews.
Common mistakes and how to improve
To optimize the PR review process, teams should avoid common pitfalls that lead to unnecessary delays. Here are some specific mistakes and actionable steps to address them:
- Neglecting documentation: Every PR should include a detailed description of the changes made, including the purpose and any relevant background information. For example, if a PR alters a function’s behavior, it is crucial to explain why the change was necessary and how it affects the overall project. This clarity helps reviewers grasp the context quickly, reducing unnecessary back-and-forth communication. For instance, a PR that simply states "fixed bug" without context could lead to multiple clarifying questions from reviewers, dragging out the process.
- Submitting large PRs: Large PRs can overwhelm reviewers and significantly slow down the process. Instead, aim to break down substantial changes into smaller, focused PRs. For example, if implementing a new feature requires modifications across several files, consider submitting each file's changes as a separate PR. This not only speeds up review time but also allows reviewers to assess the impact of each change more easily. A study shows that smaller PRs can be reviewed in an average of 5.6 days compared to 15 days for larger ones, highlighting the efficiency of this approach [n].
- Ignoring reviewer availability: Be mindful of the reviewers' existing commitments. If a reviewer is currently occupied with other tasks, their feedback may be delayed. Assign PRs to reviewers who have the capacity to provide timely reviews, or set up a rotation system to ensure balanced workloads among team members. For example, if you know that a specific reviewer is swamped with deadlines, consider assigning the PR to someone else or allowing them to opt out when they have too many commitments. This proactive approach can prevent bottlenecks in the review process.
By addressing these common issues, teams can significantly reduce PR wait times and enhance collaboration.
Questions readers ask
What should I do if my PR is taking too long to get reviewed?
If your PR is delayed, consider reaching out to the assigned reviewers for an update. Additionally, ensure that your PR is well-documented and easy to understand, which can facilitate a quicker review process.
How can I encourage more contributors to submit PRs?
To attract more contributors, create clear guidelines for submitting PRs and actively engage with potential contributors by providing feedback on their initial submissions. This can help build a supportive community around your project.
Are there tools to help manage PR reviews?
Yes, several tools can assist in managing PR reviews, including GitHub Actions for automating responses and notifications, as well as code review tools like Reviewable and CodeClimate, which can streamline the review process.
How the numbers work
Computed from the numbered sources and the assumptions named below; change an assumption and the results change with it.
| Figure | Value | Where it comes from |
|---|---|---|
| Total Pull Requests Analyzed | 111,094 | source [1] |
| Bot Response Rate | 37.38 % | source [2] |
| Human Response Rate | 72.53 % | source [2] |
| Average Wait Time for Bot PRs | 30 days | assumption: typical wait time based on available literature |
| Average Wait Time for Human PRs | 15 days | assumption: typical wait time based on available literature |
| Count of Bot PR Responses | 41,526.94 | computed: Total Pull Requests Analyzed × (Bot Response Rate ÷ 100) |
| Count of Human PR Responses | 80,576.48 | computed: Total Pull Requests Analyzed × (Human Response Rate ÷ 100) |
| Average Wait Time Difference | 15 days | computed: Average Wait Time for Bot PRs - Average Wait Time for Human PRs |
- Total Pull Requests Analyzed: 111094
- Bot Response Rate: 37.38 %
- Human Response Rate: 72.53 %
- Average Wait Time for Bot PRs: 30 days
- Average Wait Time for Human PRs: 15 days
Works out: Count of Bot PR Responses; Count of Human PR Responses; Average Wait Time Difference