def __init__(self, app, template_cache_dir=None, directories_setting=None, skip_bad_plugins=True, **kwargs): """ Set up the manager and load all visualization plugins. :type app: galaxy.app.UniverseApplication :param app: the application (and its configuration) using this manager :type base_url: string :param base_url: url to prefix all plugin urls with :type template_cache_dir: string :param template_cache_dir: filesytem path to the directory where cached templates are kept """ self.app = weakref.ref(app) self.config_parser = config_parser.VisualizationsConfigParser() self.base_url = self.BASE_URL self.template_cache_dir = template_cache_dir self.additional_template_paths = [] self.directories = [] self.skip_bad_plugins = skip_bad_plugins self.plugins = {} self.directories = config_directories_from_setting( directories_setting, app.config.root) self._load_configuration() self._load_plugins()
def __init__(self, app, directories_setting=None, skip_bad_plugins=True, **kwargs): """ Set up the manager and load all plugins. :type app: UniverseApplication :param app: the application (and its configuration) using this manager :type directories_setting: string (default: None) :param directories_setting: the filesystem path (or paths) to search for plugins. Can be CSV string of paths. Will be treated as absolute if a path starts with '/', relative otherwise. :type skip_bad_plugins: boolean (default: True) :param skip_bad_plugins: whether to skip plugins that cause exceptions when loaded or to raise that exception """ self.directories = [] self.skip_bad_plugins = skip_bad_plugins self.plugins = odict.odict() self.directories = util.config_directories_from_setting( directories_setting, app.config.root) self.load_configuration() self.load_plugins()
def __init__(self, webhooks_dirs): self.webhooks = [] self.webhooks_directories = [] for webhook_dir in config_directories_from_setting(webhooks_dirs): for plugin_dir in os.listdir(webhook_dir): path = os.path.join(webhook_dir, plugin_dir) if os.path.isdir(path): self.webhooks_directories.append(path) self.load_webhooks()
def __init__(self, app, directories_setting=None, skip_bad_plugins=True, **kwargs): """ Set up the manager and load all plugins. :type app: UniverseApplication :param app: the application (and its configuration) using this manager :type directories_setting: string (default: None) :param directories_setting: the filesystem path (or paths) to search for plugins. Can be CSV string of paths. Will be treated as absolute if a path starts with '/', relative otherwise. :type skip_bad_plugins: boolean (default: True) :param skip_bad_plugins: whether to skip plugins that cause exceptions when loaded or to raise that exception """ self.directories = [] self.skip_bad_plugins = skip_bad_plugins self.plugins = odict.odict() self.directories = util.config_directories_from_setting(directories_setting, app.config.root) self.load_configuration() self.load_plugins()
def __init__(self, app, template_cache_dir=None, directories_setting=None, skip_bad_plugins=True, **kwargs): """ Set up the manager and load all visualization plugins. :type app: UniverseApplication :param app: the application (and its configuration) using this manager :type base_url: string :param base_url: url to prefix all plugin urls with :type template_cache_dir: string :param template_cache_dir: filesytem path to the directory where cached templates are kept """ self.app = weakref.ref(app) self.config_parser = config_parser.VisualizationsConfigParser() self.base_url = self.BASE_URL self.template_cache_dir = template_cache_dir self.additional_template_paths = [] self.directories = [] self.skip_bad_plugins = skip_bad_plugins self.plugins = odict.odict() self.directories = config_directories_from_setting(directories_setting, app.config.root) self._load_configuration() self._load_plugins()
def __init__(self, tour_directories): self.tour_directories = util.config_directories_from_setting( tour_directories) self.load_tours()
def __init__(self, tour_directories): self.tour_directories = config_directories_from_setting( tour_directories) self._extensions = ('.yml', '.yaml') self._load_tours()
def __init__(self, tour_directories): self.tour_directories = util.config_directories_from_setting( tour_directories ) self.load_tours()
def __init__(self, view_directories=None, view_dicts=None): self.view_directories = config_directories_from_setting( view_directories) or [] self.view_dicts = view_dicts or []