Pylint is a Vscode python plugin that can help with code specifications and aesthetics.
But some of the errors you do not want to see, you can choose to ignore the sex.
- For example, in Re.compile (), you can add a parameter
re.S
that .
matches any character. And Pylint will keep the error. This method does not exist, resulting in a failure to run. This problem does not occur in Pycharm.
To customize the Ignore error, proceed as follows:
- Search in the Setting,json file
python.linting.pylintArgs
- Modify the following.
In the python.linting.pylintArgs
add string --disable=错误码
, if there are multiple error codes, separate the parentheses. I just ignored it here E1101
. You can change it intoE1101, E1102
Note: There is a lot of information on the Internet, many people say it is added --disable-msg=错误码
but this method does not apply to me, maybe I downloaded the latest version. The method mentioned above can be used to test.
What other questions can you leave a message to discuss.
Solve the problem of ignoring the Python plugin pylint error in Vscode