一句话:把缺陷预测模型迁移为提交回滚预测,在 Wayfair 三个仓库上平均将回滚提交排在 80% 非回滚提交之前,缺陷定位时间减少 55%。
工业界的缺陷预测模型通常只判断文件或方法是否易出缺陷,无法定位具体缺陷,实用性有限。本文把这类模型迁移到新任务:预测一次提交是否可能被回滚。作者从代码库的修订历史中抽取缺陷预测中常用的特征,训练模型对提交排序;基于大规模持续集成的批量部署场景,这能让开发者更快发现生产环境中时效性强的缺陷。在 Wayfair 网站的三个主要仓库上的实验表明,模型平均能把被回滚的提交排在 80% 以上的非回滚提交之前;交给 Wayfair 开发者使用后,查找某类缺陷所需时间减少 55%。该成果与模型至今仍被 Wayfair 用于软件部署期间发现缺陷。
Researchers have proposed many algorithms to predict software bugs. Given a software entity (e.g., a file or method), these algorithms predict whether the entity is bug-prone. However, since these algorithms cannot identify specific bugs, this does not tend to be particularly useful in practice. In this work, we adapt this prior work to the related problem of predicting whether a commit is likely to be reverted. Given the batch nature of continuous integration deployment at scale, this allows developers to find time-sensitive bugs in production more quickly. The models in this paper are based on features extracted from the revision history of a codebase that are typically used in bug prediction. Our experiments, performed on the three main repositories for the Wayfair website, show that our models can rank reverted commits above 80% of non-reverted commits on average. Moreover, when given to Wayfair developers, our models reduce the amount of time needed to find certain kinds of bugs by 55%. Wayfair continues to use our findings and models today to help find bugs during software deployments.
DOI 原文 ·
@inproceedings{paperbot5851,
title = {Adapting bug prediction models to predict reverted commits at Wayfair},
author = {Alexander Suh},
booktitle = {FSE},
year = {2020},
doi = {10.1145/3368089.3417062}
}