Coder Social home page Coder Social logo

autoflake8's People

Contributors

abravalheri avatar adhikasp avatar akeeman avatar alvarotroya avatar andrewda avatar arxell avatar cliu13 avatar dependabot[bot] avatar fsouza avatar hadialqattan avatar jamescurtin avatar myint avatar pmgrafe avatar pre-commit-ci[bot] avatar sargun avatar sh4869 avatar tell-k avatar tiangolo avatar tmshn avatar toddrme2178 avatar trim21 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

Forkers

alvarotroya

autoflake8's Issues

unused imports/variables detected message smushed into one line

When there are multiple files containing unused imports/variables, the output is written as one line.

file1.py: Unused imports/variables detectedfile2.py: Unused imports/variables detectedfile3.py: Unused imports/variables detectedfile4.py: Unused imports/variables detected

Would be easier to read if each was on its own line:

file1.py: Unused imports/variables detected
file2.py: Unused imports/variables detected
file3.py: Unused imports/variables detected
file4.py: Unused imports/variables detected

fix.py should have a trailing \n

Why remove unused import in `__init__.py`

While testing autoflake8 behavior, it seems that it always assumes unused import on __init__.py really unused. Contrary, importing constant on __init__.py is a reasonable practice. You should preserve --ignore-init-module-imports.

test_fuzz is too slow

test_fuzz is great, but it's too slow. We should split it in two components and make it concurrent: one that walks the filesystem and another one actually executes autoflake.

Could be two asyncio.Queues and a configurable number of workers working on them.

Verbosity on what autoflake fix

I don't know how to increase verbosity as said by the README. I've tested:

--remove-unused-variables -vvv tests/test_fib.py
--remove-unused-variables -v -v -v tests/test_fib.py
--remove-unused-variables -v tests/test_fib.py

All of them have same verbosity, that is: Fixed tests/test_fib.py

_

How to print the modification that had been done and what rule is violated?

Example config

Is there any example implementing arguments in .pre-commit-config.yaml or preferably pyproject.toml?

I'm using:

  - repo: https://github.com/fsouza/autoflake8
    rev: v0.3.2
    hooks:
      - id: autoflake8
        args: [--recursive --in-place --remove-unused-variables]

But returns error:

 No such file or directory: '--recursive --in-place --remove-unused-variables'

output a message on success?

At the end of a successful run, it would be nice to output a message, similar to what black does.

All done! ✨ 🍰 ✨
41 files would be left unchanged.

When I run autoflake8 on a directory that has no issues, I don't get any confirmation that it actually ran.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.