sigmf / sigmf-python

Easily interact with Signal Metadata Format (SigMF) recordings.
https://sigmf.org
GNU Lesser General Public License v3.0
42 stars 16 forks source link

project metadata: specify maximum line length for flake8/pycodestyle #37

Closed marcusmueller closed 9 months ago

marcusmueller commented 9 months ago

After throwing a bit of eyeballing on the existing code base, 120 characters seems to be a common enough and sensible choice of maximum line length

marcusmueller commented 9 months ago

I'm okay with merging this, but have you considered 88?

I hadn't; the motivation came from even sensibly short lines being broken down by my tooling; I hence opted to go with what seemed to encompass most of the current codebase

Curious what is your procedure to use flake8 and/or pycodestyle?

Neovim + pylsp reads tox.ini's [flake8], pycodestyle is used by the GNU Radio CI, and my best guess was that if we do it for one, we should do it for both tools. (very annoying they use different sections, anyways…)

Generally I run black on python code then run flake8 just to make sure I don't have unused variables or imports.

I usually use the LSP key bindings in my editor to clean up indents, empty line counts and other "mechanical" stuff, and typically only run black when I'm working on a new file – it tends to change too much on existing code bases.