Am 16.04.21 um 03:21 schrieb Barry Warsaw:
Actually, I think it’s time for a comprehensive guide to type annotations. Just anecdotally, I was trying to annotate a library of mine and was having an impossible time of it, until a chat with Guido lead me to @typing.overload. That solved my problem intuitively and easily, but I just didn’t know about it. Right now, there’s information spread out all over the place, the stdlib documentation, tool documentation, StackOverflow :D etc. It’s a complicated topic that I think a comprehensive guide, a tutorial, etc. could really help with.
As a typeshed maintainer, I agree. Currently, the typing documentation is spread over various PEPs, the typing module documentation, and the mypy documentation. We also have a style guide for stub in the typeshed documentation. That said, at least for type stubs, we are working on a PEP (still looking for a sponsor) that is supposed to be a comprehensive document.