added support for lists and fixed a bunch of misc stuff
doc fixes
Update TODOs
Merge upstream.
Manual merge of cf99740f16335e1d67e606f983eab7296da913ae