forked from TextDatasetCleaner/TextDatasetCleaner
-
Notifications
You must be signed in to change notification settings - Fork 0
/
setup.cfg
90 lines (69 loc) · 2.56 KB
/
setup.cfg
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
[flake8]
extend-exclude = .*
max-line-length = 120
extend-ignore =
# docstrings FIXME
D10,
# f-strings
WPS305,
# 'Unnecessary generator - rewrite as a set comprehension': `{}` - is ugly, `set()` - my choice
C401,
# 'Found commented out code': many false-positives
E800,
# Found class without a base class
WPS306,
# Print the total number of errors.
count = true
# Count the number of occurrences of each error/warning code and print a report.
statistics = True
# Good variable names which should always be accepted, separated by a comma.
allowed-domain-names = result,
e,
param,
params,
obj,
max-local-variables = 10
# 'WPS231 Found too high function cognitive complexity'
max-cognitive-score = 25
# 'WPS232 Found too high module cognitive complexity'
max-cognitive-average = 20
# 'WPS230 Found too many public instance attributes'
max-attributes = 10
# 'WPS211 Found too many arguments'
max-arguments = 10
per-file-ignores =
# WPS412: Found `__init__.py` module with logic
# WPS201: Found module with too many imports
src/textdatasetcleaner/processors/__init__.py: WPS412, WPS201
# FIXME: Found wrong module name
src/textdatasetcleaner/helpers.py: WPS100
# FIXME: Found too deep nesting
src/textdatasetcleaner/loaders.py: WPS220
# FIXME: subprocess call - check for execution of untrusted input.
src/textdatasetcleaner/processors/shuffle.py: S603
src/textdatasetcleaner/processors/unique.py: S603
## tests:
# WPS116: Found consecutive underscores name: test__empty
# S101: Use of assert detected. The enclosed code will be removed when compiling to optimised byte code.
# WPS226: Found string constant over-use
# WPS214: Found too many methods: 9 > 7
tests/*: WPS116, S101, WPS226, WPS214
[isort]
line_length = 120
# https://pycqa.github.io/isort/docs/configuration/profiles/
profile = pycharm
# https://pycqa.github.io/isort/#multi-line-output-modes
multi_line_output = 3
# For the import styles that use parentheses, you can control whether or not to include a trailing comma after the last import with
include_trailing_comma = True
# PyCharm optimize imports style
lines_after_imports = 2
[mypy]
disallow_incomplete_defs = True
disallow_untyped_defs = True
pretty = True
show_error_codes = True
# Skipping analyzing 'textacy.preprocessing.resources': found module butno type hints or library stubs
# https://mypy.readthedocs.io/en/latest/running_mypy.html#missing-imports
[mypy-textacy.preprocessing.resources.*]
ignore_missing_imports = True