Skip to content

Commit 3a206c1

Browse files
author
CangSpirit
committed
ci: 👷 pylint配置
1 parent 33d8f2d commit 3a206c1

2 files changed

Lines changed: 21 additions & 1 deletion

File tree

.github/workflows/pylint.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,4 +53,4 @@ jobs:
5353
echo "No Python files under src/. Skipping."
5454
exit 0
5555
fi
56-
pylint --disable=import-error,E0602 $files
56+
pylint $files

.pylintrc

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
[MESSAGES CONTROL]
2+
disable=
3+
import-error, # 动态依赖(maya / PyQt 等)缺失不报错
4+
undefined-variable, # Q* 系列变量未定义不报错
5+
missing-docstring, # 函数/类/模块缺少文档字符串
6+
line-too-long, # 行太长
7+
unused-import, # 未使用的 import
8+
too-few-public-methods,# 类方法太少
9+
too-many-arguments, # 参数过多
10+
too-many-lines, # 单文件过长
11+
duplicate-code, # 重复代码
12+
wrong-import-position, # import 顺序
13+
wildcard-import, # 通配符 import
14+
consider-using-f-string, # 建议用 f-string
15+
16+
[SIMILARITIES]
17+
ignore-comments=yes
18+
ignore-docstrings=yes
19+
ignore-imports=yes
20+
min-similarity-lines=3

0 commit comments

Comments
 (0)