Ensure docstring coverage with interrogate

XMLWordPrintableJSON

    • Type: Task
    • Resolution: Unresolved
    • Priority: Minor - P4
    • None
    • Affects Version/s: None
    • Component/s: Infrastructure
    • None
    • Python Drivers
    • None
    • None
    • None
    • None
    • None
    • None

      Context

      We have to rely on manual review to ensure that we have docstring coverage. While we have done pretty well on public APIs, a lot of our internal APIs are lacking documentation. We should consider adding interrogate to our list of manual linters.

      As a spot check:

      code
      uv tool run interrogate pymongo/ --ignore-semiprivate --ignore-private --ignore-property-decorators --ignore-init-method --ignore-nested-classes --ignore-setters
      RESULT: FAILED (minimum: 80.0%, actual: 66.8%)
      code

      Definition of done

      Add interrogate to the manual linters and ensure reasonable coverage of existing APIs.

      Pitfalls

      It may be helpful to set a low threshold and split of the work into a few PRs that each raise the limit.

            Assignee:
            Unassigned
            Reporter:
            Steve Silvester
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated: