Fixed some type annotations and reformatted some pydocs.
Update pydoc to allow None were we pass None.
Minor.