How developers search for code: a case study
By Caitlin Sadowski, Kathryn T. Stolee, Sebastian G. Elbaum. 2015
267 citations recorded by the source corpus.
With the advent of large code repositories and sophisticated search capabilities, code search is increasingly becoming a key software development activity. In this work we shed some light into how developers search for code through a case study performed at Google, using a combination of survey and log-analysis methodologies. Our study provides insights into what developers are doing and trying to learn when per- forming a search, search scope, query properties, and what a search session under different contexts usually entails. Our results indicate that programmers search for code very frequently, conducting an average of five search sessions with 12 total queries each workday. The search queries are often targeted at a particular code location and programmers are typically looking for code with which they are somewhat familiar. Further, programmers are generally seeking answers to questions about how to use an API, what code does, why something is failing, or where code is located.
Subfields: Computer Science Applications, Information Systems, Information Retrieval & Search, Human-Computer Interaction
How researchers see this paper
The researchers whose trusted networks rank it highest, strongest advocate first. Every researcher gets a different order.
In Computer Science Applications
- Armando Solar-Lezama
- Graham Neubig
- Bogdan Vasilescu
- James Koppel
- Frank F. Xu
- Varot Premtoon
- Rishabh Singh
In Information Systems
- Frank F. Xu
- Graham Neubig
- Bogdan Vasilescu
- Armando Solar-Lezama
- James Koppel
- Varot Premtoon
- Yuting Chen
- Lingxiao Jiang
In Information Retrieval & Search
- Yuting Chen
- Armando Solar-Lezama
- Lingxiao Jiang
- Graham Neubig
- Hang Yu
- Bogdan Vasilescu
- Beijun Shen
- James Koppel
In Human-Computer Interaction
Citations in the corpus
- An Empirical Study of C++ Vulnerabilities in Crowd-Sourced Code Examples (2019, methodology): “, third-party library [2], open source software [3], and Question and Answer (Q&A) websites such as Stack Overflow [4], [5].”
- Semantic code search via equational reasoning (2020, methodology): “In this work, we are concerned specifically with code searches intended to help a programmer change a codebase, measured to be 16% of code searches [69].”
- Are the Code Snippets What We Are Searching for? A Benchmark and an Empirical Study on Code Search with Natural-Language Queries (2020, methodology): “…natural-language queries were obtained from popular posts on Stack Overflow, which is fair and has also been adopted in many other researches [19]–[21]; (3) The four metrics have also been used in many researches, which have been explained in Section II; and (4) Six methods belonging to two…”
- In-IDE Code Generation from Natural Language: Promise and Challenges (2021, background): “Practically, however, many developers simply rely on generic natural-language search engines like Google to find appropriate code snippets by first locating pages that contain code snippets through natural language queries [101] on programming QA websites like Stack Overflow.”