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

ci: Introduce static type checker #410

Closed
akihironitta opened this issue Nov 27, 2020 · 3 comments · Fixed by #433
Closed

ci: Introduce static type checker #410

akihironitta opened this issue Nov 27, 2020 · 3 comments · Fixed by #433
Assignees
Labels
ci/cd Continues Integration and delivery discussion enhancement New feature or request let's do it! Looking forward to have it implemented
Milestone

Comments

@akihironitta
Copy link
Contributor

🚀 Feature

As PL has pyright type checker in ci Lightning-AI/pytorch-lightning#2093, we should have one in Bolts as well.

There are a number of type checkers, and reasonable options are:

In my humble opinion, mypy would be a better choice for the reasons listed above.

Motivation

We have type annotations in some classes and functions mainly for docs, but we're currently not sure if the added type hints are correct or not, which should be addressed.

@akihironitta akihironitta added enhancement New feature or request ci/cd Continues Integration and delivery discussion labels Nov 27, 2020
@oke-aditya
Copy link
Contributor

I guess mypy would be nice. Even torchvision uses mypy. A sample init file which might prove useful is from torchvision is here.

@akihironitta akihironitta self-assigned this Dec 4, 2020
@akihironitta
Copy link
Contributor Author

@Borda @ananyahjha93 Can I give it a go for this? I'll first make a PR adding mypy check to GH Actions and later apply type annotations to the codebase step-by-step like applying isort in PL repo.

@Borda Borda added the let's do it! Looking forward to have it implemented label Dec 7, 2020
@Borda
Copy link
Member

Borda commented Dec 7, 2020

@Borda @ananyahjha93 Can I give it a go for this? I'll first make a PR adding mypy check to GH Actions and later apply type annotations to the codebase step-by-step like applying isort in PL repo.

sure, go ahead :]

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ci/cd Continues Integration and delivery discussion enhancement New feature or request let's do it! Looking forward to have it implemented
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants