Added python3 compatibility and workaround for some DRTV changes