Skip to content

Resolve Ruff safety findings in the PyQt task model #180

Description

@ZFordDev

Ruff reports three safety findings in src/ui/pyqt/task_list.py: two B008 function-call defaults involving QModelIndex and one RUF012 mutable class attribute.

The implementation must respect Qt model override signatures and behavior. Use a safe shared invalid index or another Qt-compatible approach for defaults, and annotate or restructure the class-level role mapping so its ownership is explicit.

Acceptance criteria:

  • Both B008 findings and the RUF012 finding are resolved.
  • Qt model method signatures remain compatible.
  • Task list model tests pass, including index and role behavior.
  • No global Ruff rule is disabled.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions