TL;DR
This paper investigates why and how software developers intentionally fix their own "technical debt" (shortcuts or suboptimal solutions in code). Through a survey of over 180 developers, the study reveals that a strong sense of responsibility, coupled with a careful consideration of costs and benefits, drives developers to proactively address their self-introduced technical debt, especially for code-related issues.
What Problem Does This Paper Address?
Technical Debt (TD) is a well-known concept in software development, representing the trade-off between delivering quickly and maintaining code quality. While much research focuses on identifying and managing TD, there's a growing understanding that developers often fix the very debt they create – termed "self-fixed TD." However, previous studies primarily relied on analyzing source code, leaving a crucial question unanswered: do developers intentionally fix their own TD, and what motivates them to do so? This paper aims to bridge this gap by directly asking practitioners about their intent, rationale, and the influence of human factors on their self-fixing behavior.
Methods
The researchers employed an online survey distributed across 17 well-known Java and Python open-source software communities. The survey was designed in three steps:
- Demographic Information: Collecting data on roles, experience, project involvement, and contributions.
- General TD Questions: Assessing familiarity with TD and the frequency/reasons for introducing and self-fixing it.
- Detailed TD Questions: Focusing on specific types of debt (Code, Defect, Test, Documentation, Design) and asking about noticing and self-fixing them.
Statistical analysis, including descriptive statistics, Wilcoxon Rank Sum tests, Cliff's Delta Effect Size, Scott-Knott Effect Size Difference (ESD) tests, Fisher's exact tests, and Bonferroni-Holm corrections, was used to analyze the quantitative data. For qualitative data (reasons for self-fixing TD), an open-coding approach was used.
Datasets
The study utilized data collected from 181 participants across 17 open-source software communities (Java and Python). The participants were selected from projects with a significant number of commits and contributors to ensure their familiarity with the codebase.
Key Insights and Ideas
- Intentionality is Key: The vast majority of developers surveyed consciously and often address their own technical debt. This counters the notion that self-fixing might be accidental or superficial.
- Sense of Responsibility as a Driver: A strong sense of ownership and responsibility is the most frequently cited reason for self-fixing TD. This highlights the importance of fostering a culture where developers feel accountable for their code's quality.
- Cost-Benefit Analysis: Decisions to fix TD are not made lightly. Developers weigh various factors, including time, expected quality improvements, and confidence in the fix, indicating a pragmatic approach to debt management.
- Human Factors Matter: Developers with higher involvement (more experience, more contributions) tend to be more concerned about self-fixing TD. This suggests that experience and commitment foster a proactive attitude towards debt repayment.
- Code Debt Takes Priority: While developers acknowledge various types of debt, Code Debt issues seem to be the primary concern for self-fixing.
- Java vs. Python Nuances: While overall trends are similar, Java developers showed slightly higher certainty in self-fixing TD and were more concerned about Test Debt compared to Python developers.
Key Results
- High Familiarity: 92% of participants were familiar or somewhat familiar with technical debt.
- Frequent Self-Fixing: Over two-thirds of participants reported self-fixing TD "always," "on a regular basis," or "sometimes."
- Top Reasons for Self-Fixing:
- Sense of responsibility (41% of participants)
- Avoid higher cost (37% of participants)
- Improve maintainability (32% of participants)
- Impact of Involvement: Participants with high contribution levels were significantly more likely to have a positive attitude towards self-fixing TD. Similarly, those with more project experience showed a stronger inclination to repay their own debt.
- TD Types: Developers were most concerned about self-fixing Code Debt, followed by Defect Debt and Test Debt. Design Debt and Documentation Debt were less frequently self-fixed.
Limitations and Future Work
Limitations: * Generalizability: While the study included popular Java and Python projects, findings might not generalize to all development contexts or languages. * Statistical Transformations: The use of log-transformations in certain statistical tests might yield different results with other transformations. * Self-Reported Data: The study relies on self-reported data, which can be subject to recall bias or social desirability bias.
Future Work: * Automated Detection: Investigate how reasons for introducing and self-fixing TD can be automatically identified from software artifacts like code and documentation. * Tooling and Process Development: Develop processes and tools to better integrate TD self-fixing into TD-related decision-making. * Cross-Language and Cross-Domain Studies: Expand research to other programming languages and different types of software development environments.
Summary updated