Back to Search
Start Over
History-Driven Fix for Code Quality Issues
- Source :
- IEEE Access, Vol 7, Pp 111637-111648 (2019)
- Publication Year :
- 2019
- Publisher :
- IEEE, 2019.
-
Abstract
- To ensure the internal code quality of contributions in open source software (OSS) communities, static analysis tools (e.g. Code Climate and SonarQube) have been integrated into the modern pull-based workflow for detecting code quality issues (CQIs). Automated CQI fixing is conducive to improve the efficiency of converging massive contributions. In this paper, we propose a history-driven approach to automatically fix CQIs utilizing the fixing knowledge mined from the change history in the code repositories. We collected 5,047,678 CQI isstances, 31,013 fixes of the CQIs that were detected by SonarQube from 206 GitHub projects and mined 68 common Fix Patterns for 56 CQI types. Evaluated by fixing the unfix CQI Instances, we find that the average correctness of our approach is 80% in top 1 fix patch and 69.17% of Top 5. We further conducted a live study by sending CQI's fix patches to GitHub projects. The results show that developers approved or merged 11 of 17 patches.
Details
- Language :
- English
- ISSN :
- 21693536
- Volume :
- 7
- Database :
- Directory of Open Access Journals
- Journal :
- IEEE Access
- Publication Type :
- Academic Journal
- Accession number :
- edsdoj.39836f237e41497fa7f0abcec028028c
- Document Type :
- article
- Full Text :
- https://doi.org/10.1109/ACCESS.2019.2934975