Add more docs for shell.py so that sphinx autodoc picks it up