def checkConnection(connectionList):
    conn_id = connectionList.getCurrentItemId()
    if conn_id != -1:
        conn = connectionList.get_connection(conn_id)
        config = getConnectionInfo(connectionList, conn_id)
        if config is not None:
            config_name = config['name']
            config_id = config['id']
            try:
                test_db_connection(config)
            except VistrailsDBException:
                # assume connection is wrong
                config["create"] = False
                showConnConfig(connectionList, **config)
            else:
                del config['name']
                del config['id']
checkConnection() -> None
dataset/ETHPy150Open VisTrails/VisTrails/vistrails/gui/collection/explorer.py/checkConnection