Skip to content

[Enhancement]: Add linting and formatting checks to CI #25

Description

@shauryagangrade

Problem

The CI pipeline does not enforce code style or formatting standards. This can lead to inconsistent code style across contributions and make the codebase harder to maintain.

Proposed solution

Add linting and formatting checks to the CI pipeline:

  • Use black for code formatting
  • Use isort for import sorting
  • Use flake8 or ruff for linting
  • Use mypy for type checking
  • Add pre-commit hooks for local development

Update the CI configuration to include:

- run: pip install black isort flake8 mypy
- run: black --check gcode/
- run: isort --check-only gcode/
- run: flake8 gcode/
- run: mypy gcode/

Add a .pre-commit-config.yaml file for local development.

Alternatives considered

  • Using only black for formatting
  • Using pylint instead of flake8
  • Not enforcing any style checks

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions