half-assed python3 port