Skip to content

Introduction to Code Linting

Linting is static analysis that flags issues like:

  • unused imports/variables
  • suspicious logic
  • inconsistent style
  • complexity / maintainability issues

Linting runs without executing your code.

  • Linting: “this looks wrong / risky / inconsistent”
  • Formatting: “make code look consistent” (e.g., Black)
  • Type checking: “types don’t match” (e.g., Mypy)
diagram Diagram mermaid
  • catches bugs before runtime
  • keeps large codebases consistent
  • makes PR reviews faster

Source code typically passes through a formatter, a linter, and a type checker before a commit is allowed through the quality gate.

diagram Code Quality Gate mermaid
Source code passes through formatting, linting, and type checking before a commit is allowed.

pch.coffeeTagline

pch.coffeeCta

pch.feedbackHeading

pch.feedbackSubheading