Repository navigation
Lots of stub fixes - #15
Conversation
|
Note: with the |
|
Thanks for the PR! Your changes look good (a few minor comments above). Changing |
|
It doesn't need to wait, because a I have IMHO the right level of balance is: while typeshed should have consideration for implementations, it shouldn't make itself wrong for them. |
|
I haven't rebased this yet because I'm still investigating a proper fix for the "don't export unless" |
|
If I don't finish this in an hour, I probably won't until Monday. I discovered that mypy does have a |
|
No hurry, I won't get around to testing this PR with mypy before Monday, as well. WRT |
|
A symlink is not enough, since that will result in duplicate definitions if anybody explicitly imports it. I'll use the (working) glob import though. |
|
Switching from my versions of I have addressed all of the review comments now except for the There's actually already a bug: python/typing#112 |
|
Note, the hang you experienced is a result of creating a |
|
FYI, mypy should now deal with |
This fixes a lot of stubs so that they actually typecheck.
The only thing I didn't fix was sqlalchemy, for which I filed #14
Of note:
__builtin__so that other code can import it.typesinstead ofAnyor nonexistent names likebuiltins.module.Tuple[T](fixed-length) and also some other sequences.Anyand unparameterized containers that I happened to see while applying other updates.builtinsdoes not export typing names. There was a comment that implied that imported names were not reexported, but that is not what current tooling actually does, and there were several stubs as well as real-world code that used names likeListandDictwithout importing them.What I did not do:
bytearrayand other buffer cases).raise FooErrorcode that I don't think belongs in stubs (and which is certainly incomplete, if not inaccurate, if it is intended to enumerate all the possible exceptions).