PyCharm is a powerful Python IDE, and PEP 8 alerts are also useful, but the function name can’t contain capital letters and a few other specifications really feel bad, as a Virgo obsessive compulsive disorderPatients, the wave line below the code is absolutely not allowed to exist.
File -> Settings -> Editor -> Inspections -> right side Python”
PEP 8 coding style violation warning ID to view https://pep8.read the docs.io/en/latest/intrO.html#error-codes
PEP 8 naming convention violation alarm ID view”https://pypi.org/project/pep8-naming/
code |
sample message |
N801 |
class names should use CapWords Convention” |
N802 |
function name should be lowercase” |
N803 |
argument name should be lowercase” |
N804 |
first argument of a classmethod should be named” CLS “ |
N805 |
first argument of a method should be named” self “ |
N806 |
variable in function should be lowercase” |
N807 |
function name should not start or end with” |
N811 |
constant imported as non constant” |
N812 |
lowercase imported as non lowercase” |
N813 |
camelcase imported as lowercase” |
N814 |
camelcase imported as constant” |
as above, add N802, N803, N806 ignored, and then the world is clean.