Fix all typing issues
@fantix can you please check this?
I've dropped the Unions since they are not needed in pyi files.
I've tested this on uvicorn, it works like a charm. It would be nice to add a type checker in this repository.
EDIT: I meant the typing... 😅
Thank you! Looks there's an error: ImportError: cannot import name 'HttpParser' from 'httptools.parser.parser'
Let me add a CI workflow to check typing.
Thank you! Looks there's an error:
ImportError: cannot import name 'HttpParser' from 'httptools.parser.parser'Let me add a CI workflow to check typing.
Then it seems the issue is that the parser.pyi exists? Should be __init__.pyi? 🤔
I'm on a plane. I'll fix this tomorrow.
Thank you! Looks there's an error:
ImportError: cannot import name 'HttpParser' from 'httptools.parser.parser'Let me add a CI workflow to check typing.
It seems HttpParser is marked as internal. I've fixed it.
I've added the type checker to the pipeline, but feel free to tweak whatever you want.
Btw, this gives less frustration to people when contributing to other projects:
You can find it on: