support python output; style fixes