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

Initial mypy support #356

Open
wants to merge 23 commits into
base: main
Choose a base branch
from
Open

Initial mypy support #356

wants to merge 23 commits into from

Conversation

schnellerhase
Copy link

@schnellerhase schnellerhase commented Mar 2, 2025

Introduces a mypy linting check to the CI, and introduces fixes for some mypy checks. The remaining, for now ignored checks require more extensive changes and are left out here.

Work towards #211

@schnellerhase schnellerhase marked this pull request as ready for review March 2, 2025 13:22
@schnellerhase schnellerhase changed the title Some mypy checks Initial mypy support Mar 2, 2025
@@ -340,7 +340,7 @@ def reconstruct(self, **kwargs: typing.Any) -> Cell:
return Cell(self._cellname)


class TensorProductCell(AbstractCell):
class TensorProductCell(Cell):
Copy link
Member

Choose a reason for hiding this comment

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

Was this change deliberate? I guess we should talk to our firedrake friends (@dham) if this is something they want.

Copy link
Author

Choose a reason for hiding this comment

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

Yes, fixes

ufl/cell.py:441: error: Incompatible return value type (got "TensorProductCell", expected "Cell")  [return-value]

Not entirely sure if it is the right fix to it though.

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