Python 3 support

This adds python 3 support.