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
Make PEP-8 compatible #98
Comments
Hmm, tackled two files and got 160 errors down. This may take a while ⏳. Looks like I was counting build folder files with the initial alert estimate, so really there's 2132 left. |
Great. You'll see that I only started following the style guide a year ago or so, so good luck! I don't think you're intending to do this, but since it technically falls under the scope of this: there's loads of camelCase in function definitions where it should be lower_case_with_underscores. Note that fixing all of these might work internally, but break the public API since it relies occasionally on |
I'll avoid changing variable names, and they're not alerted by my style checker anyway. I'm also being careful about the ones where I might introduce a bug, like the 'line too long' alerts, so I'm only doing those when I'm able to test the script well. |
Some of the style change would require overly distracting updates, so I'm thinking of adding them to the ignore list for flake8 and focusing on the others for now. Below are counts for the most common errors in BookwormDB, I think at least the first two are worth ignoring for now, and maybe the next three after that. Any that are F-class are the most useful to fix, like unused imports, references to non-existent variables, and unintended redefinitions.
|
Linting is useful in finding bugs, so I'm hoping to standardize Bookworm style to PEP-8 so that more serious errors stand out. Normally I would do this without an issue, but I want to make sure it's clear what is happening, and need an excuse to just pull the band-aid on full scripts rather than fix lines here or there.
I use flake8 integrated in vim through syntastic, but that's as good as any other linter. Flake8 also works as a command line tool; it currently shows 4470 warnings or errors. It's mostly things like spacing issues, but also useful notes unused imports and variables.
The text was updated successfully, but these errors were encountered: