Skip to content

HELPME: Refactor problematic methods #31930

@ctsims

Description

@ctsims

Our static analysis tools have shown that although our overall code quality has been improving, we've stalled or regressed on the volume of really bad ('E' or 'F' grade) blocks of code.

image

I investigated the outputs specifically and as expected some of this code is in legacy custom reports or other areas of low-risk. However, a number of these blocks are just long-standing methods that have continued to grow over time into broad and complex scopes, and have been actively edited by multiple people over the last 6-12 months. These are a good value proposition for intentional re-factoring.

These blocks have been tagged in the codebase with a comment lead by HELPME. The radon static analysis tool can be used to determine whether a function still triggers an 'E' or 'F' grade

$ radon cc . --min=E --exclude=node_modules/*,staticfiles/*

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions