Understanding metric-based detectable smells in Python']Python software: A comparative study

被引:22
|
作者
Chen Zhifei [1 ]
Chen Lin [1 ]
Ma Wanwangying [1 ]
Zhou Xiaoyu [2 ]
Zhou Yuming [1 ]
Xu Baowen [1 ]
机构
[1] Nanjing Univ, State Key Lab Novel Software Technol, Nanjing 210093, Jiangsu, Peoples R China
[2] Southeast Univ, Sch Comp Sci & Engn, Nanjing 210096, Jiangsu, Peoples R China
基金
中国国家自然科学基金;
关键词
!text type='Python']Python[!/text; Code smell; Detection strategy; Software maintainability; CODE-SMELLS; BAD SMELLS; IMPACT; IDENTIFICATION; PROBABILITY; AGREEMENT;
D O I
10.1016/j.infsof.2017.09.011
中图分类号
TP [自动化技术、计算机技术];
学科分类号
0812 ;
摘要
Context Code smells are supposed to cause potential comprehension and maintenance problems in software development. Although code smells are studied in many languages, e.g. Java and C#, there is a lack of technique or tool support addressing code smells in Python. Objective: Due to the great differences between Python and static languages, the goal of this study is to define and detect code smells in Python programs and to explore the effects of Python smells on software maintainability. Method: In this paper, we introduced ten code smells and established a metric-based detection method with three different filtering strategies to specify Metric thresholds (Experience-Based Strategy, Statistics-Based Strategy, and Tuning Machine Strategy). Then, we performed a Comparative study to investigate how three detection strategies perform in detecting Python smells and how these smells affect software maintainability with different detection strategies. This study utilized a corpus of 106 Python projects with most stars on GitHub. Results: The results showed that: (1) the metric-based detection approach performs well in detecting Python smells and Tuning Machine Strategy achieves the best accuracy; (2) the three detection strategies discover some different smell occurrences, and Long Parameter List and Long Method are more prevalent than other smells; (3) several kinds of code smells are more significantly related to changes or faults in Python modules. Conclusion: These findings reveal the key features of Python smells and also provide a guideline for the choice of detection strategy in detecting and analyzing Python smells.
引用
收藏
页码:14 / 29
页数:16
相关论文
共 50 条
  • [21] A Comparative Study of Machine Learning Algorithms for the Detection of Vulnerable Python']Python Libraries
    Perez-Vilarelle, Laura
    Sotos Martinez, Eva
    Yepez Martinez, Javier
    INTERNATIONAL JOINT CONFERENCE 15TH INTERNATIONAL CONFERENCE ON COMPUTATIONAL INTELLIGENCE IN SECURITY FOR INFORMATION SYSTEMS (CISIS 2022) 13TH INTERNATIONAL CONFERENCE ON EUROPEAN TRANSNATIONAL EDUCATION (ICEUTE 2022), 2023, 532 : 138 - 148
  • [22] Investigation of a sintering phenomenon through master sintering curve based on python']python software
    Orlandini, Mayara Eid
    de Araujo, Huyra Estevao
    INTERNATIONAL JOURNAL OF APPLIED CERAMIC TECHNOLOGY, 2022, 19 (01) : 221 - 231
  • [23] Evolution of technical debt remediation in Python']Python: A case study on the Apache Software Ecosystem
    Tan, Jie
    Feitosa, Daniel
    Avgeriou, Paris
    Lungu, Mircea
    JOURNAL OF SOFTWARE-EVOLUTION AND PROCESS, 2021, 33 (04)
  • [24] Deep learning models in Python']Python for predicting hydrogen production: A comparative study
    Devasahayam, Sheila
    ENERGY, 2023, 280
  • [25] When Code Smells Twice as Much: Metric-Based Detection of Variability-Aware Code Smells
    Fenske, Wolfram
    Schulze, Sandro
    Meyer, Daniel
    Saake, Gunter
    2015 IEEE 15TH INTERNATIONAL WORKING CONFERENCE ON SOURCE CODE ANALYSIS AND MANIPULATION (SCAM), 2015, : 171 - 180
  • [26] BlastGUI: A Python']Python-based Cross-platform Local BLAST Visualization Software
    Du Zongjun
    Wu Qing
    Wang Tianzhu
    Chen Defang
    Huang Xiaoli
    Yang Wei
    Luo Wei
    MOLECULAR INFORMATICS, 2020, 39 (04)
  • [27] RE-NUM-OR: Python']Python-based Renumbering and Reordering Software for Pedigree Files
    Yazgan, Kemal
    CZECH JOURNAL OF ANIMAL SCIENCE, 2018, 63 (02) : 70 - 77
  • [28] pyPhotometry: Open source Python']Python based hardware and software for fiber photometry data acquisition
    Akam, Thomas
    Walton, Mark E.
    SCIENTIFIC REPORTS, 2019, 9 (1)
  • [29] Pycheron: A Python']Python-Based Seismic Waveform Data Quality Control Software Package
    Aur, Katherine Anderson
    Bobeck, Jessica
    Alberti, Anthony
    Kay, Phillip
    SEISMOLOGICAL RESEARCH LETTERS, 2021, 92 (05) : 3165 - 3178
  • [30] Design of Software-Defined-Satellite-based PID Attitude Control Application in Python']Python
    Zhai, Yu-Jia
    Lin, Zhe-Yuan
    PROCEEDINGS OF 2018 IEEE 4TH INFORMATION TECHNOLOGY AND MECHATRONICS ENGINEERING CONFERENCE (ITOEC 2018), 2018, : 133 - 137