Skip to content

Create documentation for performance analysis on pylint #4067

@jolaf

Description

@jolaf

In my company we have a number of Python projects, and on one of them (220 KB, 4200 lines of code) pylint is tremendously slow to run, it takes about 30 minutes on a 4-core machine. The other projects are of comparable size, functionality and complexity, and yet pylint runs reasonably fast on them. All the projects are "clean" meaning the code is working fine and all pylint errors and warnings have been cleaned up.

My purpose here is to identify the aspects of my code that cause pylint too long to process, and modify my code so that the problem would go away. I tried different things, like excluding some imports, splitting files and classes in half, etc., but the root of the problem still eludes me. Profiler also is not of much help as it just shows that time gets consumed in some pylint internals.

What I'm looking for is some ideas what to check or how to identify the problem. Maybe there are some internal mechanisms in pylint that could be used to find out which parts of the code beings checked are taking a lot of time to check?

Thanks!

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions