forked from sickmartian/quick_simplenote
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathpyproject.toml
126 lines (116 loc) · 2.88 KB
/
pyproject.toml
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
114
115
116
117
118
119
120
121
122
123
124
125
126
[tool.pyright]
typeCheckingMode = "basic"
[tool.black]
line-length = 120
# target-version = ['py310']
# include = '\.pyi?$'
extend-exclude = '''
/(
# The following are specific to Black, you probably don't want those.
tests/data
| profiling
)/
'''
[tool.autoflake]
check = true
# remove_all_unused_imports = true
remove-all-unused-imports = true
# remove_unused_variables = true
# [tool.flakehell]
# exclude = ["README.rst", "README.md"]
# format = "colored"
# max_line_length = 88
# show_source = true
# whitelist = "../../allowlist.txt"
# # unused_imports = false
[tool.pytest.ini_options]
# [tool.pytest]
minversion = "8.0.0"
pythonpath = ["."]
# addopts = "-ra -q"
addopts = [
# '-v',
"-vv",
# '-s',
"--rootdir",
"..",
"-ra",
# "-q",
"--color=yes",
"--capture=sys",
# "--capture=tee-sys",
# "-rf",
# '--reuse-db', '--no-migrations',
# "--disable-socket",
]
# 控制测试单元的打印
log_cli = true
# log_cli_level = "INFO"
# 匹配测试文件
testpaths = ["tests", "*/tests"]
python_files = ["test_*.py", "tests.py", "test.py"]
python_classes = ["Test*"]
python_functions = ["test_*"]
norecursedirs = [
"node_modules",
"venv",
"env",
"migrations",
"static",
"templates",
"docs",
"build",
"dist",
".*",
]
[tool.isort]
# reference: https://pycqa.github.io/isort/docs/configuration/options.html
# settings_file = ".isort.cfg"
atomic = true
line_length = 120
skip_gitignore = true
profile = "black"
src_paths = ["isort", "test"]
# reverse_sort = true
# tuple_bracket_spacing = true
# tuple_brackets = false
force_grid_wrap = 0
# force_grid_wrap = 4
# 是否按照嵌套顺序分组导入
force_sort_within_sections = true
# 导入顺序 例如: 在项目中应该先导入标准库、然后是第三方库、最后是自己的模块
sections = ["FUTURE", "STDLIB", "THIRDPARTY", "FIRSTPARTY", "LOCALFOLDER"]
# no_lines_before = ["FUTURE", "STDLIB", "THIRDPARTY", "FIRSTPARTY", "LOCALFOLDER"]
# 是否根据文件中导入语句的顺序对导入进行排序
force_single_line = false
# 是否在导入语句过多时分割成多行
combine_as_imports = false
# known_third_party = ["django", "rest_framework"]
# known_first_party = ["black", "blib2to3", "blackd", "_black_version"]
# known_local_folder = ["my_module3"]
# known_django = "django"
lines_after_imports = 2
lines_between_types = 1
# multi_line = 3
multi_line_output = 3
# trailing_comma = true
include_trailing_comma = true
use_parentheses = true
skip = [
"migrations",
"static",
"templates",
'node_modules',
"build",
".tox",
'venv',
'env',
"apps/*/migrations",
"apps/*/static",
"apps/*/templates",
]
extend_skip = ['.md', '.json', '.gitignore', '.dockerignore']
skip_glob = ['docs/*', "tests/data", "profiling"]
extend_skip_glob = ['my_*_module.py']
# 在导入中添加导入时间戳注释: 要求 isort=>5.5.0
# annotate = true