Skip to content

Enable unreachable code checks in lib/ with mypy#3521

Merged
svartkanin merged 1 commit intoarchlinux:masterfrom
correctmost:cm/fix-unreachable-warnings
May 28, 2025
Merged

Enable unreachable code checks in lib/ with mypy#3521
svartkanin merged 1 commit intoarchlinux:masterfrom
correctmost:cm/fix-unreachable-warnings

Conversation

@correctmost
Copy link
Contributor

PR Description:

With this PR, unreachable checks will now be performed on the entire codebase.

Tests and Checks

  • I have tested the code

@correctmost correctmost requested a review from Torxed as a code owner May 28, 2025 09:47
return asdict(o)
else:
return o.__dict__
return o.__dict__ # type: ignore[unreachable]
Copy link
Contributor Author

Choose a reason for hiding this comment

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

I added an ignore for now because I'm not sure if this line can be reached.

This function has other typing issues, so the ignore can be revisited after the other issues are addressed.

@svartkanin svartkanin merged commit c2f4d92 into archlinux:master May 28, 2025
9 checks passed
@correctmost correctmost deleted the cm/fix-unreachable-warnings branch May 28, 2025 10:51
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.

2 participants