当前位置:网站首页>Vscode configuration uses pylint syntax checker
Vscode configuration uses pylint syntax checker
2022-07-07 14:10:00 【jiang_ huixin】
- First installation “Python” plug-in unit

- install
pylintGrammar checker
It is recommended to install on the current Python Environment
pip3 install pylint
- Enable
pylintGrammar checker
open VSCode Configuration file for

Add the following :
{
// Code checking
"python.linting.enabled": true,
"python.linting.pylintEnabled": true,
// preservation Python Check syntax on file
"python.linting.lintOnSave": true
}
- To configure
pylintGrammar checker
establish .pylintrc file
pylint --generate-rcfile > .pylintrc
among pylint be located Python Environmental Science ( Installed in this environment pylint) Medium bin Catalog , Running the above command may require specifying pylint The absolute path of
And then what will be generated .pylintrc Move the file to the root directory of the project
stay VSCode Add configuration to configuration :
{
// Appoint .pylintrc The path of , ${workspaceFolder} Represents the root directory of the current project
"python.linting.pylintArgs": [
"--rcfile=${workspaceFolder}/.pylintrc"
]
}
If pylint Not installed in VSCode Current Python Environmental Science , You need to add the following configurations ( Need to be revised pylint Actual path of )
{
// Appoint pylint The path of
"python.linting.pylintPath": "${env:HOME}/Miniconda/bin/pylint"
}
- Disable some check items
pylint There is an over check , The following is a prompt for not writing the module document string :

Yes 3 There are three levels of methods to disable such prompts :
- Add comments to the code
# pylint: disable=missing-module-docstring

- modify pylint Operation parameters of
modify VSCode Configuration of
The following shows how to disable invalid-name and missing-module-docstring Two inspection items :
{
"python.linting.pylintArgs": [
"--rcfile=${workspaceFolder}/.pylintrc",
"--disable=invalid-name,missing-module-docstring"
]
}
- modify .pylintrc file
stay .pylintrc Search for “diable”, Add an item at the end “missing-module-docstring”
disable=raw-checker-failed,
bad-inline-option,
locally-disabled,
file-ignored,
suppressed-message,
useless-suppression,
deprecated-pragma,
use-symbolic-message-instead,
not-callable,
missing-module-docstring
边栏推荐
- Learning breakout 2 - about effective learning methods
- Seven propagation behaviors of transactions
- Excuse me, why is it that there are no consumption messages in redis and they are all piled up in redis? Cerely is used.
- When FC connects to the database, do you have to use a custom domain name to access it outside?
- Excuse me, I have three partitions in Kafka, and the flinksql task has written the join operation. How can I give the join operation alone
- 手把手教会:XML建模
- Excuse me, when using Flink SQL sink data to Kafka, the execution is successful, but there is no number in Kafka
- Xshell connection server changes key login to password login
- PostgreSQL array type, each splice
- 供应链供需预估-[时间序列]
猜你喜欢

最长上升子序列模型 AcWing 1014. 登山
![供应链供需预估-[时间序列]](/img/2c/82d118cfbcef4498998298dd3844b1.png)
供应链供需预估-[时间序列]

一个简单LEGv8处理器的Verilog实现【四】【单周期实现基础知识及模块设计讲解】

Build a secure and trusted computing platform based on Kunpeng's native security

Evolution of customer service hotline of dewu

2022-7-6 Leetcode 977.有序数组的平方

LeetCode简单题分享(20)

Social responsibility · value co creation, Zhongguancun network security and Information Industry Alliance dialogue, wechat entrepreneur Haitai Fangyuan, chairman Mr. Jiang Haizhou

.net core 关于redis的pipeline以及事务

2022-7-7 Leetcode 34.在排序数组中查找元素的第一个和最后一个位置
随机推荐
[untitled]
Parsing of XML files
Excellent open source system recommendation of ThinkPHP framework
Oracle advanced (V) schema solution
【日常训练--腾讯精选50】231. 2 的幂
mysql ”Invalid use of null value“ 解决方法
Vmware 与主机之间传输文件
gvim【三】【_vimrc配置】
Common response status codes
社会责任·价值共创,中关村网络安全与信息化产业联盟对话网信企业家海泰方圆董事长姜海舟先生
wpf dataGrid 实现单行某个数据变化 ui 界面随之响应
Interface automation test - solution of data dependency between interfaces
Dry goods | summarize the linkage use of those vulnerability tools
648. Word replacement: the classic application of dictionary tree
Environment configuration
Flask session forged hctf admin
Advanced Mathematics - Chapter 8 differential calculus of multivariate functions 1
How does MySQL control the number of replace?
118. 杨辉三角
PHP中用下划线开头的变量含义