Example #1
0
def import_workflow(path, admin_gi, user_gi):
    """Import a workflow path to specified Galaxy instance."""
    importer = BioBlendImporterGalaxyInterface(
        admin_gi=admin_gi,
        user_gi=user_gi
    )
    workflow = _raw_dict(path, importer)
    return importer.import_workflow(workflow)
Example #2
0
def import_workflow(path, admin_gi, user_gi, from_path=False):
    """Import a workflow path to specified Galaxy instance."""
    if not from_path:
        importer = BioBlendImporterGalaxyInterface(admin_gi=admin_gi,
                                                   user_gi=user_gi)
        workflow = _raw_dict(path, importer)
        return importer.import_workflow(workflow)
    else:
        # TODO: Update bioblend to allow from_path.
        payload = dict(from_path=path)
        workflows_url = user_gi._make_url(user_gi.workflows)
        workflow = Client._post(user_gi.workflows, payload, url=workflows_url)
        return workflow
Example #3
0
def import_workflow(path, admin_gi, user_gi, from_path=False):
    """Import a workflow path to specified Galaxy instance."""
    if not from_path:
        importer = BioBlendImporterGalaxyInterface(
            admin_gi=admin_gi,
            user_gi=user_gi
        )
        workflow = _raw_dict(path, importer)
        return importer.import_workflow(workflow)
    else:
        # TODO: Update bioblend to allow from_path.
        path = os.path.abspath(path)
        payload = dict(
            from_path=path
        )
        workflows_url = user_gi._make_url(user_gi.workflows)
        workflow = Client._post(user_gi.workflows, payload, url=workflows_url)
        return workflow
Example #4
0
def import_workflow(path, admin_gi, user_gi, from_path=False):
    """Import a workflow path to specified Galaxy instance."""
    if not from_path:
        importer = BioBlendImporterGalaxyInterface(admin_gi=admin_gi,
                                                   user_gi=user_gi)
        workflow = _raw_dict(path, importer)
        return user_gi.workflows.import_workflow_dict(workflow)
    else:
        path = os.path.abspath(path)
        workflow = user_gi.workflows.import_workflow_from_local_path(path)
        return workflow
Example #5
0
def import_workflow(path, admin_gi, user_gi, from_path=False):
    """Import a workflow path to specified Galaxy instance."""
    if not from_path:
        importer = BioBlendImporterGalaxyInterface(admin_gi=admin_gi,
                                                   user_gi=user_gi)
        workflow = _raw_dict(path, importer)
        return user_gi.workflows.import_workflow_dict(workflow)
    else:
        # TODO: Update bioblend to allow from_path.
        path = os.path.abspath(path)
        payload = dict(from_path=path)
        workflows_url = user_gi.url + '/workflows'
        workflow = user_gi.workflows._post(payload, url=workflows_url)
        return workflow
Example #6
0
def import_workflow(path, admin_gi, user_gi):
    """Import a workflow path to specified Galaxy instance."""
    importer = BioBlendImporterGalaxyInterface(admin_gi=admin_gi,
                                               user_gi=user_gi)
    workflow = _raw_dict(path, importer)
    return importer.import_workflow(workflow)