MichaelKim0407 / flake8-use-fstring

MIT License
51 stars 7 forks source link

modulo operations cause a FS001 #20

Closed fscherf closed 2 years ago

fscherf commented 2 years ago

When using % for modulo like in 10 % 2 == 0, flake8-use-fstrings seems to think python2.7 style string formatting is used

MichaelKim0407 commented 2 years ago

Are you using the default greedy level?

fscherf commented 2 years ago

@MichaelKim0407 its set to 2 (https://github.com/lona-web-org/lona/blob/master/flake8.ini#L21)

MichaelKim0407 commented 2 years ago

Working as intended. Please refer to readme.

Depending on your project (whether you use % for maths a lot), my suggestions are:

fscherf commented 2 years ago

@MichaelKim0407 Oh! I am sorry, i missed that. Thanks for the fast response!

MichaelKim0407 commented 2 years ago

No problem!