The bug report says one thing.

The code says another.

A REAL BUG · MARKOR

Text retrieval ranked the buggy file 35th.

THE MISSING CLUE

Yet the buggy screen pointed right at it.

BUG REPORT

New file dialogue always says Type: Markdown rather than previous type used

1. Create a new file, change type to e.g. todo.txt, save it

2. Create another new file …

Window: NewFileDialog
BUGLOCATOR · RANKED FILES
An empirical study

Can the GUI close the gap?

Four text-retrieval baselines, augmented with GUI data from each bug’s reproduction.

01 · MAP THE GUI TO CODE

Link screens to source files.

Activity and window names match class files; component IDs lead to the files with their event listeners.

02 · RE-RANK

Filter. Then boost.

Drop files unrelated to the reproduction’s screens, and lift GUI-related files to the top, keeping their order.

03 · REFORMULATE

Or rewrite the query.

Expand the bug report with GUI terms, or replace it with them outright.

Activity: MainActivity
Window: NewFileDialog
RANKED FILES
QUERY
new file dialogue always says type markdown rather than previous type used …
+ MainActivity NewFileDialog MoreFragment fab_add_new_item
EXPANSION · HELPS
REPLACEMENT · RARELY HELPS
Studied on
0
real, reproducible bugs
0
open-source Android apps
0
augmented configurations
Finding 1
0–0%
relative gain in Hits@10, across all four baselines
Filter + boostis the best re-ranking for every baseline
7–8 more bugsreach the top 10, with none pushed out
3 screensbuggy screen + 2 before it work best on average

On Using GUI Interaction Data to Improve Text Retrieval-based Bug Localization

Junayed Mahmud · Nadeeshan De Silva · Safwat Ali Khan · Seyed Hooman Mostafavi · S M Hasan Mansur · Oscar Chaparro · Andrian Marcus · Kevin Moran
ICSE 2024 · IEEE/ACM International Conference on Software Engineering