improvements, bug fixes for python generation
a lot of fixes/improvements for the std lib