Skip to content

Conversation

@miketheman
Copy link

Introduce mypy and apply strict type hints.
Declare typed support via marker file and classifier.

@miketheman
Copy link
Author

Relies on #27 for a clean lint run.

return True

return attempt + 1 == attempts
return attempt + 1 == attempts # type: ignore[no-any-return] # TODO: what's the best way to determine these?
Copy link
Author

Choose a reason for hiding this comment

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

I'm not certain how to inspect these, since both attempt and attempts could be t.Any, due to the untyped nature of request.environ (a dict) and they are being set earlier on.

I contemplated adding assert isinstance(attempt, int); assert isinstance(attempts, int) but that felt clunky too.

Introduce `mypy` and apply strict type hints.
Declare typed support via marker file and classifier.

Signed-off-by: Mike Fiedler <[email protected]>
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.

1 participant