Skip to content

BUG : Branch & Joining Broken : Branch not being taken #685

Closed

Description

@r39132

I running on HEAD master (as of nov 23 morning) and also confirmed this on 1.6.0.

I am seeing 2 sorts of broken behavior around branching and joining. This bug captures the left side of the decision, and #680 captures the right side of the decision.

I am seeing 2 types of broken behavior with respect to branching and joining. One is captured on #680

The other behavior is that the left side of the branch is not executed even when the branch operator says it will take it. Essentially, as shown below by the red rectangle in both the graph and tree views, the build_sender_models_spark_job to check_for_successful_model_building_branch_condition subdag is not being executed, though the check_for_time_to_build_model_branch_condition is specifying it.

screenshot 2015-11-23 12 09 51

screenshot 2015-11-23 12 04 50

The aggregate_data_spark_job task is defined below.

aggregate_data_spark_job = BashOperator(
    task_id='aggregate_data_spark_job',
    execution_timeout=timedelta(hours=3),
    trigger_rule='one_success',
    priority_weight=5,
    pool='ep_data_pipeline_spark_tasks_only',
    bash_command=optional_aggregation_templated_command,
    params={'ENV': ENV,
            'import_spark_cluster_ip': import_spark_cluster_ip,
            'granularity_secs': import_airflow_granularity_secs,
            'compute_end_dt' : compute_end_dt},
    dag=dag)
aggregate_data_spark_job.set_upstream(check_for_successful_model_building_branch_condition)
aggregate_data_spark_job.set_upstream(check_for_time_to_build_model_branch_condition)

Activity

  1. changed the title [-]BUG : Branch not being taken[/-] [+]BUG : Branch & Joining Broken : Branch not being taken[/+] on Nov 23, 2015
  2. mistercrunch commented on Nov 23, 2015

    @mistercrunch
    Member

    Is depends_on_past enabled here? If so I think it may be a byproduct of #680

  3. r39132 commented on Nov 23, 2015

    @r39132
    ContributorAuthor

    Yes, "depends_on_past" is enabled. However, how are they related? It's easy for me to test this theory. I will go ahead and set it to "depends_on_past"=false and test it out.

  4. mistercrunch commented on Nov 23, 2015

    @mistercrunch
    Member

    depends_on_past currently means "the previous task instance for this DAG succeeded"

    if that is the definition, it's somewhat incompatible with branching.

    If the definition has to be changed, it's unclear what it should be changed to. Seem that whatever change would not be immediately intuitive whatever it may be.

  5. r39132 commented on Nov 24, 2015

    @r39132
    ContributorAuthor

    For this to work, I need to change depends_on_past to false. I also needed to change my DAG so that the join point was not a direct child of the branch point.

    Here's my new DAG :
    screenshot 2015-11-23 17 15 21

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions