* asyncio: remove BaseChildWatcher from top level
* asyncio.sleep: loop is keyword-only
* asyncio: remove Server from top level
* asyncio: add FastChildWatcher to top level
* asyncio.constants: fix version availability
* asyncio: fix arg name for _wakeup
* asyncio: fix arg name for wrap_future
* asyncio.streams: add Optional to various arguments
It might be possible to further improve some of these with overloads.
* stubtest: fix whitelist
Co-authored-by: hauntsaninja <>
* flake8 updates and cleanups
* Update to flake8 3.7.9.
* Update to flake8-bugbear 20.1.4.
* Only ignore errors in stub files.
* Remove obsolete error counts.
* Sort error codes alphabetically.
* Don't ignore the following errors (unneeded):
* E704 Multiple statements on one line (def)
* W504 Line break occurred after a binary operator
* B303 __metaclass__ used
* Remove obsolete comment
* Ignore F822 undefined name in __all__
* typing: fix argument names of cast
* typing: use private _Alias class
For py37 and above, this is _GenericAlias, for py36 and below it's
_TypeAlias. I don't think we need to make typing.pyi definitions
correspond more precisely, but we should avoid leaking a
typing.TypeAlias class
- connect_accepted_socket isn't a member of AbstractEventLoop, only
BaseEventLoop
- fix types of arguments with defaults. some of these functions could
have their signatures improved with overloads to reduce false negatives
- correctly mark a positional-only argument
- remove abstractmethod from methods that don't have abstractmethod and
go unimplemented in practice
It doesn't actually have __call__, it does some descriptor stuff, but
this makes things work. _SingleDispatchCallable has a __call__ too,
which is what this mirrors.
Fixes#3898
NodeVisitor recurses over an AST tree. When encountering a node, it
checks if a method called `visit_{node.__class__.__name__}` exists, and
calls it if so, otherwise calls the generic visitor.
Add the possible methods to NodeVisitor. This is not exactly correct,
since the methods don't *actually* exist on NodeVisitor, e.g.
`NodeVisitor().visit_Module(...)` doesn't work. But it's nice for
subclasses to know which methods they can override and which type they
should have.
* Add macurl2path stub, types based on urllib
* Fix types, remove undocumented
The whole module is undocumented, no reason to just mention it on one call
* Module was removed in 3.7, stubtest shouldn't care about it
* Module was removed in 3.7, stubtest shouldn't care about it
* ssl: fix arg names, mark positional-only args
* ssl: add undocumented parameter to do_handshake
* ssl: fix type of password in load_cert_chain
* ssl: add session parameter to wrap_socket, wrap_bio in py36 on
* ssl: update whitelists
travis seems to have just updated from 3.7.5 to 3.7.6 and 3.8.0 to
3.8.1. The stubs match the newer versions, so we remove the previously
whitelisted error.
* sre_parse: NIC is stub implementation detail
* sre_parse: add missing arg to Tokenizer.getuntil
* sre_parse: fix types for parse
* sre_parse: fix types for SubPattern.__init__
* sre_parse: fix arg name for fix_flags
* sre_parse: update whitelists
* sre_parse: fix some availability for py35