C:\Users\dominic.lopes\Desktop>pylint Exception.py ************* Module Exception Exception.py:1:0: C0103: Module name "Exception" doesn't conform to snake_case naming style (invalid-name) Exception.py:11:4: C0103: Constant name "x" doesn't conform to UPPER_CASE naming style (invalid-name) Exception.py:12:4: C0103: Constant name "y" doesn't conform to UPPER_CASE naming style (invalid-name) Exception.py:21:44: E0602: Undefined variable 'count' (undefined-variable)
您的代码已被评为 3.85/10(上一次运行:6.92/10,-3.08)
这是我得到的错误回溯
最佳答案
如果您使用的是更新版本的 pylint(即 >1.7),则需要通过 -ry
或 --reports=yes
到 pylint,如 pylint <your file> --reports=yes
.报告部分现在在较新的版本中默认禁用,因此您必须手动激活它。
关于python - 我已经安装了pylint。但它不会按类型、原始指标、重复等显示统计信息。表。如何让 pylint 显示它?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/51823322/