forked from zulip/zulip-terminal
-
Notifications
You must be signed in to change notification settings - Fork 0
/
setup.cfg
113 lines (100 loc) · 3.14 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
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
[tool:pytest]
xfail_strict=true
filterwarnings =
# distutils: imp module is deprecated in favor of importlib
# * python3.6/3.7/3.8
ignore::DeprecationWarning:distutils.*:
# bs4: ABCs must be imported from collections.abc, not collections, from python3.9
# * python 3.7/3.8
ignore::DeprecationWarning:bs4.*:
addopts =
-rxXs
--cov=zulipterminal
--no-cov-on-fail
[tool:isort]
# Use black for the default settings (with adjustments listed below)
profile=black
# For compatibility with 'black' we'd want to set this consistently
line_length=88
atomic=True
# This is compatible with black, but we could remove it
lines_after_imports=2
# flake8 takes a little more time than pycodestyle, but finds more things
# (we could also look at pylint, zulint, etc.)
[flake8]
max-line-length=88
ignore=
# E121 - continuation line under-indented for hanging indent
E121,
# E123 - closing bracket does not match indentation of opening bracket's line
E123,
# E126 - continuation line over-indented for hanging indent
E126,
# W503 - line break before binary operator - new PEP8 best practice, cf W504
W503,
# E203 - Colons should not have any space before them (conflicts with black)
E203,
# E241 - Multiple spaces after ',' - breaks layouts like themes files
E241,
# E221 - Multiple spaces before operator - breaks layouts like theme files
E221,
# E252 - Spaces in parameters, a style deliberately avoided
E252,
# E501 - Ignore max-line-length property - this is already defined by black
E501,
# F841 - assigned to but never used - FIXME: indicates potential issues
F841,
# Q000 - inline quotes - FIXME: standardize on " or ' in future?
Q000,
inline-quotes = "
multiline-quotes = """
exclude=.git,__pycache__,build,dist,zt_venv
[mypy]
python_version = 3.6
# Logistics of what code to check and how to handle the data.
# mypy_path = stubs/
scripts_are_modules = True
show_traceback = True
cache_dir = .mypy_cache
# Options to make the checking stricter, as would be mypy --strict
# (in order of mypy --help docs for --strict)
warn_unused_configs = True
disallow_any_generics = True
disallow_subclassing_any = False
disallow_untyped_calls = False
disallow_untyped_defs = True
disallow_incomplete_defs = True
check_untyped_defs = True
disallow_untyped_decorators = False
no_implicit_optional = True
warn_redundant_casts = True
warn_unused_ignores = True
warn_return_any = False
no_implicit_reexport = False
strict_equality = True
# These are now defaults and we could remove them
warn_no_return = True
strict_optional = True
# If a library is typed, that's fine, otherwise don't worry
ignore_missing_imports = True
[coverage:run]
branch = True
omit =
# a/b.py,
# fizz/buzz/bar.py
[coverage:report]
exclude_lines =
# Have to re-enable the standard pragma
pragma: no cover
# Don't complain about missing debug-only code:
def __repr__
if self\.debug
# Don't complain if tests don't hit defensive assertion code
raise AssertionError
raise NotImplementedError
# Don't complain if non-runnable code is not run:
if 0:
if __name__ == .__main__.:
precision = 1
skip_covered = True
show_missing = True