Skip to content

Conversation

@ryankert01
Copy link
Contributor

Added mypy static type checking to pre-commit hooks.

Purpose of PR

Add mypy for static type checking and lock file checking

Related Issues or PRs

Closes #652

Changes Made

  • Bug fix
  • New feature
  • Refactoring
  • Documentation
  • Test
  • CI/CD pipeline
  • Other

Breaking Changes

  • Yes
  • No

Checklist

  • Added or updated unit tests for all changes
  • Added or updated documentation for all changes
  • Successfully built and ran all unit tests or manual tests locally
  • PR title follows "MAHOUT-XXX: Brief Description" format (if related to an issue)
  • Code follows ASF guidelines

Added mypy static type checking to pre-commit hooks.
@github-project-automation github-project-automation bot moved this to Backlog in QDP Nov 29, 2025
@ryankert01 ryankert01 changed the base branch from main to dev-qdp November 29, 2025 13:23
@ryankert01 ryankert01 changed the base branch from dev-qdp to main November 29, 2025 13:24
Signed-off-by: ryankert01 <ryan980053@gmail.com>
@ryankert01
Copy link
Contributor Author

@guan404ming @rich7420 @400Ping PTAL, I think we can first make to to main branch, then make it to qdp

@ryankert01 ryankert01 marked this pull request as ready for review November 29, 2025 13:45
Copy link
Member

@guan404ming guan404ming left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, left some comments

name: ruff formatting
files: \.py$

# Static type checking
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Some of comments seems redundant please help remove them, thanks!
Also let's use the newest version https://github.com/pre-commit/mirrors-mypy/releases/tag/v1.19.0

@guan404ming
Copy link
Member

We usually prefix the pr title with issue number for main branch related dev, please help update it, thanks!

@ryankert01 ryankert01 changed the title [Feature] Add mypy for static type checking and lock file checking MAHOUT:652 [Feature] Add mypy for static type checking and lock file checking Nov 29, 2025
@ryankert01 ryankert01 changed the title MAHOUT:652 [Feature] Add mypy for static type checking and lock file checking MAHOUT-652 [Feature] Add mypy for static type checking and lock file checking Nov 29, 2025
@rich7420
Copy link
Contributor

it's "MAHOUT-XXX: "
except for this. LGTM

Signed-off-by: ryankert01 <ryan980053@gmail.com>
@guan404ming guan404ming changed the title MAHOUT-652 [Feature] Add mypy for static type checking and lock file checking MAHOUT-652: Add mypy for static type checking and lock file checking Nov 29, 2025
Copy link
Member

@guan404ming guan404ming left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thanks for the quick update!

@guan404ming guan404ming merged commit 987a588 into apache:main Nov 29, 2025
3 checks passed
@github-project-automation github-project-automation bot moved this from Backlog to Done in QDP Nov 29, 2025
@ryankert01 ryankert01 deleted the improve-pre-commit-python branch November 29, 2025 14:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

[Feature] Improve python pre-commit hook

4 participants