pycodestyle_magic
pycodestyle_magic copied to clipboard
max_line_length option ignored
It looks like the max_line_length
option for flake8
is being ignored in my setting. Can you see what I'm doing wrong?
Note that if I include --ignore E231
the warning message is suppressed, so that option seems to be working.
Here's the raw code for my example:
%load_ext pycodestyle_magic
%flake8_on --max_line_length 60
import numpy as np
import pandas as pd
import string
pd.DataFrame(np.random.randn(100,26), columns=list(string.ascii_uppercase))
len("pd.DataFrame(np.random.randn(100,26), columns=list(string.ascii_uppercase))")
Thanks for raising the issue! Your code gives me the following:

Which raises on the line that is too long. I'm on pycodestyle_magic
version 0.5
. But funny enough the last line that you mention doesn't work for me either.
My pycodestyle_magic
version is also 0.5
. Can you think of what else the difference could be?
Hm. Its hard to say. The settings are parsed to flake8
here:
flake = flake8_module.get_style_guide(
extend_ignore=ignore_codes,
max_line_length=max_line_length
)
If I do:
import flake8
flake8.__version__
I got version 3.7.9
. What version are you on?
But since the ignore_codes
part for you is working.. that probably won't be the problem
Ya, I'm on 3.7.9
also.