This is probably due to missing __all__ variables in certain places.
We don't plan to fully support mypy --strict until the 2.0.0 release (see roadmap). Until then you can disable those specific errors with mypy --strict --implicit-reexport (read more here).
I get this when running
mypy --string
on my code:The relevant line is just:
This is how pymongo solved the same issue: https://jira.mongodb.org/browse/PYTHON-3311