fixed raise error to check conn_str instead of dsn