Skip to content

Change ruff to docformatter 1.7.8 #28

@stevenhua0320

Description

@stevenhua0320

Problem

We want to change back to docformatter to be consistent with the lint check

Proposed solution

replace the block of code

 # ruff - An extremely fast Python linter and code formatter, written in Rust.
  - repo: https://github.com/astral-sh/ruff-pre-commit
    rev: v0.15.12
    hooks:
      - id: ruff-check
        args: [--fix, --config, ./pyproject.toml]

to

- repo: https://github.com/PyCQA/docformatter
    rev: v1.7.8
    hooks:
      - id: docformatter
        additional_dependencies: [tomli]
        args: [--in-place, --config, ./pyproject.toml]

in the .pre-commit-config.yaml and change

[tool.ruff]
line-length = 72

[tool.ruff.lint.pydocstyle]
convention = "numpy"

to

[tool.docformatter]
recursive = true
wrap-summaries = 72
wrap-descriptions = 72

in the pyproject.toml

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions