Kludex / python-multipart

A streaming multipart parser for Python.
https://kludex.github.io/python-multipart/
Other
306 stars 52 forks source link

Add type support via py.typed marker file for PEP561 #147

Closed jogo-openai closed 3 months ago

jogo-openai commented 3 months ago

As per PEP561 mypy requires a py.typed file to consider a library typed. https://mypy.readthedocs.io/en/latest/installed_packages.html#creating-pep-561-compatible-packages.

Adding this file will allow folks to take advantage of the typing already present in this module.

Otherwise mypy reports:

Skipping analyzing "multipart.multipart": module is installed, but missing library stubs or py.typed marker [import-untyped]

Kludex commented 3 months ago

It's a warning that makes sense, since it's untyped...