Add a py.typed file, to make types available downstream - #2314
Conversation
This will not change any behavior of this package, but it is required for consuming projects to read any existing type information here. This file is required to exist and should be empty. There's no alternative mechanism. See: https://blog.whtsky.me/tech/2021/dont-forget-py.typed-for-your-typed-python-package/ This follows django-commons#2227.
|
If we don't have everything using type annotations, is that going to cause problems for someone using mypy? |
No, not at all, it'll be the same as someone with local code / functions that aren't fully typed. In short, MyPy will infer untyped things as Personally, I think it's a nuisance that PEP 561 makes us include this, but it's just become a routine practice. Also, note that |
|
Thank you for that explanation @brianhelba! I'll merge this once the docs/linter passes. |
Description
This will not change any behavior of this package, but it is required for consuming projects to read any existing type information here.
This file is required to exist and should be empty. There's no alternative mechanism. See: https://blog.whtsky.me/tech/2021/dont-forget-py.typed-for-your-typed-python-package/
This follows #2227.
docs/changes.rst.