DEIA improves crash repair accuracy and efficiency for HarmonyOS apps

DEIA: Evidence-Grounded Crash Repair with Change-Aware Test Design for HarmonyOS ArkTS

Software Engineering

Summary

Fixing mobile apps that crash isn’t just about finding the problem, but also making sure the fix works and doesn’t break anything else. The authors present DEIA, a process designed to repair HarmonyOS apps by using AI suggestions combined with careful checks for testing and building the app. Their tests show DEIA finds closer fixes faster and more efficiently than a previous method. However, it still needs to prove it can fully preserve all app behaviors after a fix.

What this means in practice

  • For mobile app developers: Produce more accurate and efficient crash fixes tailored to HarmonyOS apps with fewer AI model calls and faster patch generation.
  • For software testing teams: Use DEIA’s change-aware test design to link source edits with runtime behavior and testing outcomes in HarmonyOS applications.

Authors

Xuhui Lu, Zhihao Liu, Xiaoke Fang, Yuhuan Fan, Yanzhe Tang, Xiaohui Wan, Xiaoyu Wu, Zheng Zheng

Abstract

Mobile crash repair requires more than identifying a source edit. Developers must establish how the edit relates to the reported failure and whether the modified application can be built, launched, and exercised without disrupting valid behavior. In HarmonyOS applications, this assessment also depends on platform-specific packaging and runtime execution. To address this need, we present DEIA, an evidence-grounded workflow for HarmonyOS crash repair. DEIA constructs a bounded source-evidence package, uses a large language model to propose content-anchored edits, and relies on a deterministic writer to materialize and check the patch. It derives fail-to-pass (F2P) obligations from the reported fault and pass-to-pass (P2P) obligations from the potential impact of the patch. A stage-level ledger links the patch, test obligations, runtime observations, and candidate-generation cost. We evaluate DEIA on 30 repair tasks from 24 HarmonyOS applications and compare it with an OpenHands-based workflow on 29 matched tasks. DEIA's first-added-line location exactly matches the curated reference in 25/29 tasks (86.2%), compared with 19/29 (65.5%) for OpenHands, a difference of 20.7 percentage points. DEIA also uses 81.5% fewer tokens, makes 60.8% fewer model calls, and takes 34.9% less candidate-generation time on average. Only two of the 58 behavior-specific P2P obligations were executed, both for one repair pattern; comprehensive behavior preservation therefore remains unestablished.