diff options
author | Patrick Cloke <clokep@users.noreply.github.com> | 2023-09-08 11:24:36 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-09-08 11:24:36 -0400 |
commit | aa483cb4c905bbe483ffe8e8a8f439655a57481b (patch) | |
tree | 4c361dd18b1731e371e55975350d408ddfa96efe /pyproject.toml | |
parent | Log values at DEBUG level with execute_values (#16281) (diff) | |
download | synapse-aa483cb4c905bbe483ffe8e8a8f439655a57481b.tar.xz |
Update ruff config (#16283)
Enable additional checks & clean-up unneeded configuration.
Diffstat (limited to 'pyproject.toml')
-rw-r--r-- | pyproject.toml | 28 |
1 files changed, 17 insertions, 11 deletions
diff --git a/pyproject.toml b/pyproject.toml index 5b43abe907..8747782b29 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -43,33 +43,39 @@ target-version = ['py38', 'py39', 'py310', 'py311'] [tool.ruff] line-length = 88 -# See https://github.com/charliermarsh/ruff/#pycodestyle +# See https://beta.ruff.rs/docs/rules/#error-e # for error codes. The ones we ignore are: -# E731: do not assign a lambda expression, use a def # E501: Line too long (black enforces this for us) +# E731: do not assign a lambda expression, use a def # # flake8-bugbear compatible checks. Its error codes are described at -# https://github.com/charliermarsh/ruff/#flake8-bugbear -# B019: Use of functools.lru_cache or functools.cache on methods can lead to memory leaks +# https://beta.ruff.rs/docs/rules/#flake8-bugbear-b # B023: Functions defined inside a loop must not use variables redefined in the loop -# B024: Abstract base class with no abstract method. ignore = [ - "B019", "B023", - "B024", "E501", "E731", ] select = [ - # pycodestyle checks. + # pycodestyle "E", "W", - # pyflakes checks. + # pyflakes "F", - # flake8-bugbear checks. + # flake8-bugbear "B0", - # flake8-comprehensions checks. + # flake8-comprehensions "C4", + # flake8-2020 + "YTT", + # flake8-slots + "SLOT", + # flake8-debugger + "T10", + # flake8-pie + "PIE", + # flake8-executable + "EXE", ] [tool.isort] |