Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Making pycodestyle faster #754

Open
wants to merge 3 commits into
base: main
Choose a base branch
from
Open

Making pycodestyle faster #754

wants to merge 3 commits into from

Commits on Apr 15, 2018

  1. Cut run_check

    `run_check` works by iterating over a list of strings, then
    dynamically accessing the appropriate checker attributes. Dynamic
    attribute access is slow, and doing it in a tight loop is really slow.
    Speed can be improved significantly by passing the checker in as an
    argument to the check and calling the attributes directly. This
    requires some argument shuffling.
    nickdrozd committed Apr 15, 2018
    Configuration menu
    Copy the full SHA
    04ce2dd View commit details
    Browse the repository at this point in the history
  2. Cut init_checker_state

    `init_checker_state` gets called a lot, but why? Performance can be
    improved by doing it just once.
    nickdrozd committed Apr 15, 2018
    Configuration menu
    Copy the full SHA
    37db846 View commit details
    Browse the repository at this point in the history
  3. Cut check argument names

    Checks were being stored along with their "argument names", but only
    `run_check` and `init_checker_state` were being using them, so they
    can be cut.
    nickdrozd committed Apr 15, 2018
    Configuration menu
    Copy the full SHA
    994f71f View commit details
    Browse the repository at this point in the history