TUTCRIS - Tampereen teknillinen yliopisto


Does code quality affect pull request acceptance? An empirical study



JulkaisuJournal of Systems and Software
DOI - pysyväislinkit
TilaE-pub ahead of print - 2020
OKM-julkaisutyyppiA1 Alkuperäisartikkeli


Background: Pull requests are a common practice for making contributions and reviewing them in both open-source and industrial contexts.

Objective: Our goal is to understand whether quality flaws such as code smells, anti-patterns, security vulnerabilities, and coding style violations in a pull request's code affect the chance of its acceptance when reviewed by a maintainer of the project.

Method: We conducted a case study among 28 Java open-source projects, analyzing the presence of 4.7 M code quality flaws in 36 K pull requests. We analyzed further correlations by applying logistic regression and six machine learning techniques. Moreover, we manually validated 10% of the pull requests to get further qualitative insights on the importance of quality issues in cases of acceptance and rejection.

Results: Unexpectedly, quality flaws measured by PMD turned out not to affect the acceptance of a pull request at all. As suggested by other works, other factors such as the reputation of the maintainer and the importance of the delivered feature might be more important than other qualities in terms of pull request acceptance.

Conclusions:. Researchers have already investigated the influence of the developers’ reputation and the pull request acceptance. This is the first work investigating code style violations and specifically PMD rules. We recommend that researchers further investigate this topic to understand if different measures or different tools could provide some useful measures.



Latausten tilastot

Ei tietoja saatavilla