Make postgresql change python3 compatible