How to use the ephemeris.ephemeris_log.setup_global_logger function in ephemeris

To help you get started, we’ve selected a few ephemeris examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github galaxyproject / ephemeris / ephemeris / shed_tools_old.py View on Github external
def main():
    global log
    disable_external_library_logging()
    options = _parse_cli_options()
    log = setup_global_logger(name=__name__, log_file=options.log_file)
    install_tool_manager = None
    if options.tool_list_file or options.tool_yaml or \
            options.name and options.owner and (options.tool_panel_section_id or options.tool_panel_section_label):
        if options.action == "update":
            sys.exit("update command can not be used together with tools to be installed.")
        install_tool_manager = get_install_repository_manager(options)
        if options.action == "test":
            install_tool_manager.test_repositories()
        else:
            install_tool_manager.install_repositories()
    elif options.update_tools:
        install_tool_manager = get_install_repository_manager(options)
        install_tool_manager.install_repositories()
    else:
        sys.exit("Must provide a tool list file, individual tools info , a list of data manager tasks or issue the update command. "
                 "Look at usage.")
github galaxyproject / ephemeris / ephemeris / shed_tools_old.py View on Github external
def _ensure_log_configured(name):
    # For library-style usage - just ensure a log exists and use ephemeris name.
    if 'log' not in globals():
        global log
        log = setup_global_logger(name)