I was recently introduced to Ruff a python linter. I have an existing directory with lots of files. I thought to try it out and made a pyproject.toml file in the directory. I want to set the line-length high (150) to show less errors but the default (88) keeps appearing. I also tried the ignore option but that does not seem to work either. Do I need to type a command to initiate the use of the pyproject.toml?
code from pyproject.toml
[tool.ruff]
extend-select = ["C4", "NPY", "PD", "SIM", "TCH"]
ignore = ["E501"]
show-fixes = true
# target-version = "py310"
# change the default line length number or characters.
line-length = 150
Another option is to have the linter ignore line lengths.
ruff check -v .
it will output something like[2023-09-26][14:21:16][ruff_cli::resolve][DEBUG] Using pyproject.toml (parent) at /home/uittenbroek/projects/myproject/pyproject.toml
– Strategyline-length = 150
at the top rather than at the bottom? [tool.ruff] line-length = 150 indent-width = 4 [tool.ruff.lint] select = ["C","E","F","W"] ignore = ["E501"] – Chromaticity