import importlib


def _bot_exists(botname):
    """
    Utility method to import a bot.
    """
    module = None
    try:
        module = importlib.import_module('%s.%s' % (botname, botname))
    except ImportError as e:
        quit('Unable to import bot "%s.%s": %s' % (botname, botname, str(e)))

    return module