Write a Blog >>
ASE 2020
Mon 21 - Fri 25 September 2020 Melbourne, Australia
Wed 23 Sep 2020 01:10 - 01:30 at Koala - Recommender Systems for Software Engineering Chair(s): Shaowei Wang

API misuses cause significant problem in software development. Existing methods detect API misuses against frequent API usage patterns mined from codebase. They make a naive assumption that API usage that deviates from the most-frequent API usage is a misuse. However, there is a big knowledge gap between API usage patterns and API usage caveats in terms of comprehensiveness, explainability and best practices. In this work, we propose a novel approach that detects API misuses directly against the API caveat knowledge, rather than API usage patterns. We develop open information extraction methods to construct a novel API-constraint knowledge graph from API reference documentation. This knowledge graph explicitly models two types of API-constraint relations (call-order and condition-checking) and enriches return and throw relations with return conditions and exception triggers. It empowers the detection of three types of frequent API misuses - missing calls, missing condition checking and missing exception handling, while existing detectors mostly focus on only missing calls. As a proof-of-concept, we apply our approach to Java SDK API Specification. Our evaluation confirms the high accuracy of the extracted API-constraint relations. Our knowledge-driven API misuse detector achieves 0.60 (68/113) precision and 0.28 (68/239) recall for detecting Java API misuses in the API misuse benchmark MuBench. This performance is significantly higher than that of existing pattern-based API misused detectors. A pilot user study with 12 developers shows that our knowledge-driven API misuse detection is very promising in helping developers avoid API misuses and debug the bugs caused by API misuses.

Wed 23 Sep
Times are displayed in time zone: (UTC) Coordinated Universal Time change

ase-2020-papers
01:10 - 02:10: Research Papers - Recommender Systems for Software Engineering at Koala
Chair(s): Shaowei WangMississippi State University
ase-2020-papers01:10 - 01:30
Talk
Xiaoxue RenZhejiang University, Xinyuan YeAustralian National University, Zhenchang XingAustralian National University, Australia, Xin XiaMonash University, Xiwei XuData61 at CSIRO, Australia, Liming ZhuData61 at CSIRO, Australia / UNSW, Australia, Jianling SunZhejiang University
Pre-print
ase-2020-papers01:30 - 01:50
Talk
Fang LiuPeking University, Ge LiPeking University, Yunfei ZhaoPeking University, Zhi JinPeking University
ase-2020-tool-demonstrations01:50 - 02:00
Talk
Chenqian ZhuNanjing University, Weisong SunState Key Laboratory for Novel Software Technology, Nanjing University, Qin LIU, Yangyang YuanNanjing University, Chunrong FangNanjing University, China, Yong HuangState Key Laboratory for Novel Software Technology, Nanjing University