text: Title: [MNT] move linting to `ruff`, resolve strange linting behaviour
  Body: We should move the linting to `ruff` - good first issue for a maintenance affine contributor.
  
  There are also some strange behaviours in the precommits which I cannot pinpoint, e.g., the linter insisting on long single lines instead of line breaks where they would be appropriate. Though I would hope this is resolved as a side effect of moving to `ruff`.