improved error handling in case no psycopg2 is installed on machine