Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

(RUF012) Fixed mutable class Defaults- Task 3 #10284

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

drona-gyawali
Copy link
Contributor

@drona-gyawali drona-gyawali commented Jan 6, 2025

Part of #10196

This PR addresses Part of RUF012 Rule - Task 3, implementing typing.ClassVar across 4 files with a total of 13 changes. The updates primarily focus on enhancing code quality and resolving linting issues (RUF012) related to mutable class attributes.

Technical

  • Updated mutable class attributes in 4 files to use typing.ClassVar for clarity and correctness.
  • Added ClassVar annotations to mutable class attributes to ensure they are treated as class-level attributes.
  • Ensured proper type hints for clarity and type safety.

Testing

Ran ruff check --select RUF012 to confirm no further warnings.

Screenshot

  • N/A

Stakeholders

@RayBB

Copy link
Collaborator

@RayBB RayBB left a comment

Choose a reason for hiding this comment

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

Looks great to me but I'll need to get a double check from staff :)

@RayBB RayBB added the Needs: Staff / Internal Reviewed a PR but don't have merge powers? Use this. label Jan 7, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Affects: Developers Needs: Staff / Internal Reviewed a PR but don't have merge powers? Use this.
Projects
Status: Waiting Review/Merge from Staff
Development

Successfully merging this pull request may close these issues.

2 participants