summaryrefslogtreecommitdiff
path: root/.ruff.toml
diff options
context:
space:
mode:
authorSimeon Simeonov2026-06-05 07:11:03 +0200
committerSimeon Simeonov2026-06-05 07:11:03 +0200
commit742fcdfabaeed8f9f70e14165cc9740f5b17d5a8 (patch)
tree7ac25ffe633cf6d36ead4e8cf2cce9f230936f6e /.ruff.toml
parent7b66519eb4ebe119e5fdc9c1eb6a11fdfab9b7bf (diff)
Add support for storing data permanently
Diffstat (limited to '.ruff.toml')
-rw-r--r--.ruff.toml49
1 files changed, 9 insertions, 40 deletions
diff --git a/.ruff.toml b/.ruff.toml
index 956737c..9018176 100644
--- a/.ruff.toml
+++ b/.ruff.toml
@@ -4,57 +4,29 @@ line-length = 79
4target-version = "py314" 4target-version = "py314"
5 5
6[lint] 6[lint]
7select = ["ALL", "D101", "D102", "D103", "D104"] 7select = ["ALL"]
8ignore = [ 8ignore = [
9 "ANN",
10 "BLE001", 9 "BLE001",
11 "COM812", 10 "COM812",
12 "D", 11 "D2",
13 "EM101", # Exception must not use a string literal, assign to variable first 12 "D4",
14 "EM102", # Exception must not use an f-string literal, assign to variable first
15 "ERA001",
16 #"FBT001",
17 #"FBT002",
18 #"INP001",
19 #"ISC001",
20 #"N802",
21 #"N806",
22 #"PLR2004",
23 # "PTH111",
24 # "PTH123",
25 "RUF012",
26 #"RUF013",
27 #"S101",
28 "S308",
29 #"T201",
30 "TRY003",
31 "TRY300",
32 #"UP020"
33] 13]
34 14
35# C901 - `outside_temperature` is too complex (12 > 10) 15# ARG005 - Unused lambda argument: `args`
16# BLE001 - Do not catch blind exception: `Exception`
36# D101 - Missing docstring in public class 17# D101 - Missing docstring in public class
37# D102 - Missing docstring in public method 18# D102 - Missing docstring in public method
38# D200 - One-line docstring should fit on one line 19# E721 - Use `is` and `is not` for type comparisons, or `isinstance()` for isinstance checks
39# D203 - 1 blank line required before class docstring
40# D205 - 1 blank line required between summary line and description
41# D403 - First word of the first line should be capitalized: `str` -> `Str`
42# ERA001 - Found commented-out code 20# ERA001 - Found commented-out code
43# FBT001 - Boolean-typed positional argument in function definition 21# FBT001 - Boolean-typed positional argument in function definition
44# FBT002 - Boolean default positional argument in function definition 22# FBT002 - Boolean default positional argument in function definition
45# INP001 - File `beinc_weechat.py` is part of an implicit namespace package. Add an `__init__.py` 23# INP001 - File `beinc_weechat.py` is part of an implicit namespace package. Add an `__init__.py`
46# N802 - Function name `do_GET` should be lowercase 24# PT008 - Use `return_value=` instead of patching with `lambda`
47# N806 - Variable `POST_data` in function should be lowercase
48# PTH111 - `os.path.expanduser()` should be replaced by `Path.expanduser()`
49# PTH123 - `open()` should be replaced by `Path.open()`
50# PLR0912 - Too many branches (13 > 12)
51# PLR0913 - Too many arguments in function definition (6 > 5)
52# PLR2004 - Magic value used in comparison, consider replacing `200` with a constant variable 25# PLR2004 - Magic value used in comparison, consider replacing `200` with a constant variable
53# RUF012 - Mutable class attributes should be annotated with `typing.ClassVar` 26# RUF012 - Mutable class attributes should be annotated with `typing.ClassVar`
54# RUF013 - PEP 484 prohibits implicit `Optional` 27# RUF013 - PEP 484 prohibits implicit `Optional`
55# S101 - Use of `assert` detected 28# S101 - Use of `assert` detected
56# S308 - Use of `mark_safe` may expose cross-site scripting vulnerabilities 29# S324 - Probable use of insecure hash functions in `hashlib`: `md5`
57# S603 - `subprocess` call: check for execution of untrusted input
58# T201 - `print` found 30# T201 - `print` found
59# TRY003 - Avoid specifying long messages outside the exception class 31# TRY003 - Avoid specifying long messages outside the exception class
60# TRY300 - Consider moving this statement to an `else` block 32# TRY300 - Consider moving this statement to an `else` block
@@ -75,7 +47,7 @@ indent-style = "space"
75skip-magic-trailing-comma = true 47skip-magic-trailing-comma = true
76 48
77# Like Black, automatically detect the appropriate line ending. 49# Like Black, automatically detect the appropriate line ending.
78line-ending = "lf" 50line-ending = "auto"
79 51
80# Enable auto-formatting of code examples in docstrings. Markdown, 52# Enable auto-formatting of code examples in docstrings. Markdown,
81# reStructuredText code/literal blocks and doctests are all supported. 53# reStructuredText code/literal blocks and doctests are all supported.
@@ -93,6 +65,3 @@ docstring-code-line-length = "dynamic"
93 65
94[lint.flake8-quotes] 66[lint.flake8-quotes]
95inline-quotes = "single" 67inline-quotes = "single"
96
97[lint.isort]
98split-on-trailing-comma = false