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

WIP: Use ruff for PEP8 checks #352

Closed
wants to merge 7 commits into from
Closed

WIP: Use ruff for PEP8 checks #352

wants to merge 7 commits into from

Conversation

hagenw
Copy link
Member

@hagenw hagenw commented Feb 13, 2023

This uses ruff for PEP8 checking, which is much faster than flake8.

It requires pyproject.toml for it's configuration, which is also added here.
But I suggest to first make an extra pull request in which we switch to pyproject.toml as it now seems mayor enough and we can replace setup.cfg and setup.py by using it.

TODO:

  • check if build Python package still looks ok
  • editable builds as done with pip -e . still do require a setup.py, so we should check if we really need this

@hagenw hagenw changed the title Use ruff for PEP8 checks WIP: Use ruff for PEP8 checks Feb 14, 2023
@frankenjoe
Copy link
Collaborator

This uses ruff for PEP8 checking, which is much faster than flake8.

How much faster is it? flake8 never seemed like a bottleneck to me.

@frankenjoe
Copy link
Collaborator

But I suggest to first make an extra pull request in which we switch to pyproject.toml as it now seems mayor enough and we can replace setup.cfg and setup.py by using it.

Yes, makes sense.

@hagenw
Copy link
Member Author

hagenw commented Feb 14, 2023

This uses ruff for PEP8 checking, which is much faster than flake8.

How much faster is it? flake8 never seemed like a bottleneck to me.

image

(from https://github.com/charliermarsh/ruff)

Now that we use pre-commit to check for flake8 you have a slight delay every time you do a commit. For most of our projects you do not feel this, but for larger ones like audformat there is a small delay.

@hagenw
Copy link
Member Author

hagenw commented Jul 11, 2023

Closing in favor of #383

@hagenw hagenw closed this Jul 11, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants