jbesomi/texthero

introducing flake8 to Texthero

mk2510 opened this issue ยท 5 comments

I was thinking, that we could improve our overall code quality by using some checker or style guide tools like flake8. From my previous experiences, Uni and Work it was a huge benefit ๐Ÿš€ :octocat:

We are already using black, right? As far as I can tell there is no benefit of running flake8 on top of black, I'm missing something?

I got this idea from this post. Flake8 is basically a code linter, which will do some basic static checks. This will help us to prevent basic bugs, like using a variable before it was assigned, etc... . This is especially helpful as python is an interpreted language and in the worst case, some code lines aren't executed with our tests but by some users the first time.

It also should be a bit stricter by coding guidelines so we have a uniformer coding style.

Black won't do those things, but just formats the code right.

Hey @mk2510, have you ever used flake8 before? It would be great to test it on the current codebase and see how many advices it provides. Would you mind try it and let us know?

Hej @jbesomi I used style guides in other projects and languages before. As I am running short on time this July, as my BT takes more time than expected I will have the time again in August to do those tests. ๐Ÿ˜‡ :octocat:

Ok, let's talk soon! Thanks, and good luck with your BT!