Skip to content

chore(typing): update renamed and unused ty ignore comments - #3002

Open
LoweRAM wants to merge 1 commit into
canonical:mainfrom
LoweRAM:fix/ty-renamed-rules
Open

LoweRAM wants to merge 1 commit into
canonical:mainfrom
LoweRAM:fix/ty-renamed-rules

Conversation

@LoweRAM

@LoweRAM LoweRAM commented Nov 25, 2026

Copy link
Copy Markdown
Contributor

Summary

Update ty: ignore[...] directives for rule renames and resolved suppressions in ty 0.0.110 (fixing lint / files failure seen on #2995):

  • invalid-mutable-override → incompatible-mutable-override
  • invalid-method-override → incompatible-method-override
  • invalid-property-type-override → incompatible-property-override
  • unresolved-attribute → missing-attribute
  • Remove unused # ty: ignore[invalid-assignment] in tests/unit/parts/plugins/test_poetry.py and test_python.py

Verification

  • uv tool run ty@0.0.110 check --python .venv charmcraft tests -> All checks passed
  • ruff check on all modified files -> All checks passed

@lengau
lengau marked this pull request as ready for review November 25, 2026 18:40
@lengau
lengau requested review from a team and a lite review from Copilot November 25, 2026 18:40

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🟢 Approval recommended

The review found no active issues, and the diagnostic updates were verified by passing type-checker and lint checks without changing runtime behavior.

No open issues 🎉

What changed in this PR

Updates ty: ignore[...] directives to the diagnostic names used by ty 0.0.110 and removes suppressions that are no longer needed, without changing runtime behavior.

Changes:

  • Renamed override and attribute diagnostics throughout the source and tests.
  • Removed unused invalid-assignment suppressions from the Poetry and Python plugin tests.
  • Verified that the updated type-checker and lint checks pass.
File Description
tests/​unit/​parts/​plugins/​test_python.py Removes an unused invalid-assignment suppression.
tests/​unit/​parts/​plugins/​test_poetry.py Removes an unused invalid-assignment suppression.
tests/​unit/​parts/​plugins/​test_charm.py Renames attribute diagnostics to missing-attribute.
tests/​integration/​commands/​test_store_commands.py Renames an attribute diagnostic to missing-attribute.
tests/​commands/​test_store_client.py Renames method and property override diagnostics.
charmcraft/​parts/​plugins/​_python.py Renames the mutable override diagnostic for Python plugin options.
charmcraft/​parts/​plugins/​_poetry.py Renames the mutable override diagnostic for Poetry plugin options.
charmcraft/​models/​project.py Renames mutable override diagnostics on project model fields.
charmcraft/​models/​config.py Renames mutable override diagnostics on Juju configuration fields.

Review effort: Lite

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants