Detecting and Characterizing Developer Behavior Following Opportunistic Reuse of Code Snippets from the Web

Modern software development is social and relies on many online resources and tools. In this paper, we study opportunistic code reuse from the Web, e.g. when developers copy code snippets from popular Q&A sites and paste them into their projects. Our focus is the behavior of developers following opportunistic code reuse, which reveals the success or failure of the action. We study developer behavior via a large, representative dataset of micro-interactions in the IDE. Our analysis of developer behavior exhibited in this dataset confirms laboratory study observations that code reuse from the Web is followed by heavy editing, in some cases by a rapid undo, and rarely by the execution of tests.

[1]  Philip J. Guo,et al.  Writing Code to Prototype, Ideate, and Discover , 2009, IEEE Software.

[2]  Christopher S. Corley,et al.  Web usage patterns of developers , 2015, 2015 IEEE International Conference on Software Maintenance and Evolution (ICSME).

[3]  Nicholas A. Kraft,et al.  A Genetic Algorithm for Computing Class Integration Test Orders for Aspect-Oriented Systems , 2012, 2012 IEEE Fifth International Conference on Software Testing, Verification and Validation.

[4]  Lori L. Pollock,et al.  Interactive Exploration of Developer Interaction Traces using a Hidden Markov Model , 2016, 2016 IEEE/ACM 13th Working Conference on Mining Software Repositories (MSR).

[5]  Philip J. Guo,et al.  Two studies of opportunistic programming: interleaving web foraging, learning, and writing code , 2009, CHI.

[6]  Johannes Schneider,et al.  Mining Sequences of Developer Interactions in Visual Studio for Usage Smells , 2017, IEEE Transactions on Software Engineering.

[7]  Nicholas A. Kraft,et al.  A Framework for Estimating Interest on Technical Debt by Monitoring Developer Activity Related to Code Comprehension , 2014, 2014 Sixth International Workshop on Managing Technical Debt.

[8]  Martin P. Robillard,et al.  Asking and answering questions about unfamiliar APIs: An exploratory study , 2012, 2012 34th International Conference on Software Engineering (ICSE).

[9]  Lori L. Pollock,et al.  A field study of how developers locate features in source code , 2016, Empirical Software Engineering.

[10]  Jeffrey C. Carver,et al.  Effects of cloned code on software maintainability: A replicated developer study , 2013, 2013 20th Working Conference on Reverse Engineering (WCRE).

[11]  Nicholas A. Kraft,et al.  What information about code snippets is available in different software-related documents? An exploratory study , 2017, 2017 IEEE 24th International Conference on Software Analysis, Evolution and Reengineering (SANER).

[12]  Sebastian Proksch,et al.  Enriched Event Streams: A General Dataset for Empirical Studies on In-IDE Activities of Software Developers , 2018, 2018 IEEE/ACM 15th International Conference on Mining Software Repositories (MSR).

[13]  Cristina V. Lopes,et al.  Stack Overflow in Github: Any Snippets There? , 2017, 2017 IEEE/ACM 14th International Conference on Mining Software Repositories (MSR).

[14]  Collin McMillan,et al.  Pragmatic source code reuse via execution record and replay , 2016, J. Softw. Evol. Process..

[15]  Robert J. Walker,et al.  Systematizing pragmatic software reuse , 2012, TSEM.

[16]  Nicholas A. Kraft,et al.  A case study of program comprehension effort and technical debt estimations , 2016, 2016 IEEE 24th International Conference on Program Comprehension (ICPC).

[17]  Zhenchang Xing,et al.  What help do developers seek, when and how? , 2013, 2013 20th Working Conference on Reverse Engineering (WCRE).