Affiliation:
1. Aarhus University, Denmark
Abstract
JavaScript libraries are widely used and evolve rapidly. When adapting client code to non-backwards compatible changes in libraries, a major challenge is how to locate affected API uses in client code, which is currently a difficult manual task. In this paper we address this challenge by introducing a simple pattern language for expressing API access points and a pattern-matching tool based on lightweight static analysis.
Experimental evaluation on 15 popular npm packages shows that typical breaking changes are easy to express as patterns. Running the static analysis on 265 clients of these packages shows that it is accurate and efficient: it reveals usages of breaking APIs with only 14% false positives and no false negatives, and takes less than a second per client on average. In addition, the analysis is able to report its confidence, which makes it easier to identify the false positives. These results suggest that the approach, despite its simplicity, can reduce the manual effort of the client developers.
Funder
European Research Council
Publisher
Association for Computing Machinery (ACM)
Subject
Safety, Risk, Reliability and Quality,Software
Cited by
16 articles.
订阅此论文施引文献
订阅此论文施引文献,注册后可以免费订阅5篇论文的施引文献,订阅后可以查看论文全部施引文献
1. Maltracker: A Fine-Grained NPM Malware Tracker Copiloted by LLM-Enhanced Dataset;Proceedings of the 33rd ACM SIGSOFT International Symposium on Software Testing and Analysis;2024-09-11
2. Bloat beneath Python’s Scales: A Fine-Grained Inter-Project Dependency Analysis;Proceedings of the ACM on Software Engineering;2024-07-12
3. Understanding the Impact of APIs Behavioral Breaking Changes on Client Applications;Proceedings of the ACM on Software Engineering;2024-07-12
4. Comparing Execution Trace Using Merkle- Tree to Detect Backward Incompatibilities;2024 IEEE International Conference on Software Analysis, Evolution and Reengineering (SANER);2024-03-12
5. npm-follower: A Complete Dataset Tracking the NPM Ecosystem;Proceedings of the 31st ACM Joint European Software Engineering Conference and Symposium on the Foundations of Software Engineering;2023-11-30