26d237186b852c342691aedfe81ac23851445f03,polyaxon/scheduler/tasks/notebooks.py,,projects_notebook_start,#Any#,50

Before Change


        _logger.warning("Notebook does not exist anymore.")
        return None

    if notebook_job.last_status == JobLifeCycle.RUNNING:
        _logger.warning("Notebook is already running.")
        return None

    try:
        image_name, image_tag = get_image_info(build_job=notebook_job.build_job)
    except ValueError as e:
        _logger.warning("Could not start the notebook, %s", e)

After Change


        _logger.warning("Notebook does not exist anymore.")
        return None

    if not JobLifeCycle.can_transition(status_from=notebook_job.last_status,
                                       status_to=JobLifeCycle.SCHEDULED):
        _logger.info("Notebook `%s` cannot transition from `%s` to `%s`.",
                     notebook_job.unique_name, notebook_job.last_status, JobLifeCycle.SCHEDULED)

    notebook_scheduler.start_notebook(notebook_job)


@celery_app.task(name=SchedulerCeleryTasks.PROJECTS_NOTEBOOK_STOP, ignore_result=True)
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 5

Instances


Project Name: polyaxon/polyaxon
Commit Name: 26d237186b852c342691aedfe81ac23851445f03
Time: 2018-06-07
Author: mouradmourafiq@gmail.com
File Name: polyaxon/scheduler/tasks/notebooks.py
Class Name:
Method Name: projects_notebook_start


Project Name: polyaxon/polyaxon
Commit Name: 26d237186b852c342691aedfe81ac23851445f03
Time: 2018-06-07
Author: mouradmourafiq@gmail.com
File Name: polyaxon/scheduler/tasks/tensorboards.py
Class Name:
Method Name: tensorboards_start


Project Name: home-assistant/home-assistant
Commit Name: ab8c127a4a466f2c137239c0eb06c8143adea106
Time: 2018-11-18
Author: JeffLIrion@users.noreply.github.com
File Name: homeassistant/components/media_player/firetv.py
Class Name:
Method Name: setup_platform