Thrift python lib reworked.