Skip to content

Nested chords bug fixes (3538) - #4301

Closed
zpl wants to merge 1 commit into
celery:masterfrom
zpl:nested-chord-bug-fix
Closed

zpl wants to merge 1 commit into
celery:masterfrom
zpl:nested-chord-bug-fix

Conversation

@zpl

@zpl zpl commented Sep 28, 2017 •

Copy link
Copy Markdown
Contributor

Fixes #3538

Description

there is pipeline:

chord([
        chord([
            chord([echo.si(name='111'), echo.si(name='112'), ], body=echo.si(name='11_')),
            chord([echo.si(name='121'), echo.si(name='122'), ], body=echo.si(name='12_')),
        ], body=echo.si(name='1_end')),
        chord([
            chord([echo.si(name='211'), echo.si(name='212'), ], body=echo.si(name='21_')),
            chord([echo.si(name='221'), echo.si(name='222'), ], body=echo.si(name='22_')),
        ], body=echo.si(name='2_end')),
        chord([
            chord([echo.si(name='311'), echo.si(name='312'), ], body=echo.si(name='31_')),
            chord([echo.si(name='321'), echo.si(name='322'), ], body=echo.si(name='32_')),
        ], body=echo.si(name='3_end')),
    ], body=echo.si(name='end')
    )

so we expect name=end to be called after 1_end and 2_end and so on.

but this pipeline generates wrong message body.

It set name='end' and chord callback for name='11_' so echo.si(name='1_end') never called.

original payload:

[
    [],
    {
        "name": "111"
    },
    {
        "chord": {
            "chord_size": 2,
            "task": "cel.echo",
            "subtask_type": null,
            "kwargs": {
                "name": "11_"
            },
            "args": [],
            "immutable": true,
            "options": {
                "chord_size": null,
                "chord": {
                    "chord_size": 3,
                    "task": "cel.echo",
                    "subtask_type": null,
                    "kwargs": {
                        "name": "end"
                    },
                    "args": [],
                    "immutable": true,
                    "options": {
                        "reply_to": "44672db2-fc8c-373b-ad89-327d193640df",
                        "task_id": "d1d7892c-c8cf-46cb-ad95-9620d6997f7b"
                    }
                },
                "task_id": "56afba7e-bcaf-4230-af7b-d4ad91fc915b",
                "root_id": null,
                "add_to_parent": false,
                "parent_id": null,
                "reply_to": "44672db2-fc8c-373b-ad89-327d193640df",
                "group_id": "90588403-d6db-48c4-8b4b-43c98bd4e1a6"
            }
        },
        "callbacks": null,
        "errbacks": null,
        "chain": null
    }
]

correct payload is:

[
    [],
    {
        "name": "111"
    },
    {
        "chord": {
            "chord_size": 2,
            "task": "cel.echo",
            "subtask_type": null,
            "kwargs": {
                "name": "11_"
            },
            "args": [],
            "immutable": true,
            "options": {
                "chord_size": null,
                "chord": {
                    "chord_size": 2,
                    "task": "cel.echo",
                    "subtask_type": null,
                    "kwargs": {
                        "name": "1_end"
                    },
                    "args": [],
                    "immutable": true,
                    "options": {
                        "chord_size": null,
                        "chord": {
                            "chord_size": 3,
                            "task": "cel.echo",
                            "subtask_type": null,
                            "kwargs": {
                                "name": "end"
                            },
                            "args": [],
                            "immutable": true,
                            "options": {
                                "reply_to": "55fa006b-9cf4-32e2-bcdf-a16e9cebcaa9",
                                "task_id": "c81f0dca-644e-4a68-ac3c-fa9970434a36"
                            }
                        },
                        "task_id": "7b2dcf81-480f-463f-819f-323d80754f09",
                        "root_id": null,
                        "add_to_parent": false,
                        "parent_id": null,
                        "reply_to": "55fa006b-9cf4-32e2-bcdf-a16e9cebcaa9",
                        "group_id": "4f5e6cd4-900d-46a0-b43f-74ec012802ff"
                    }
                },
                "task_id": "dcf4ffb7-8643-4927-993c-dc65f07427bc",
                "root_id": null,
                "add_to_parent": false,
                "parent_id": null,
                "reply_to": "55fa006b-9cf4-32e2-bcdf-a16e9cebcaa9",
                "group_id": "5d029999-b9da-4e0f-b7ab-6cffc0f17a81"
            }
        },
        "callbacks": null,
        "errbacks": null,
        "chain": null
    }
]

@thedrow thedrow left a comment •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you please add a unit test and an integration test for this fix to ensure the bug won't regress?

@zpl

zpl commented Oct 1, 2017

Copy link
Copy Markdown
Contributor Author

@thedrow, to be honest, I'm out of time - I spent a lot of time on fixing this bug and me is not so good with python/unit tests, so this will take me more time.

However, I can offer 30$ for someone, who will write tests for this case.

@thedrow

thedrow commented Nov 24, 2017

Copy link
Copy Markdown
Contributor
{
   "task":"celery.chord",
   "args":[

   ],
   "kwargs":{
      "kwargs":{

      },
      "header":{
         "task":"celery.group",
         "args":[

         ],
         "kwargs":{
            "tasks":[
               {
                  "task":"celery.chord",
                  "args":[

                  ],
                  "kwargs":{
                     "kwargs":{
                        "kwargs":{
                           "kwargs":{

                           }
                        }
                     },
                     "header":{
                        "task":"celery.group",
                        "args":[

                        ],
                        "kwargs":{
                           "tasks":[
                              {
                                 "task":"celery.chord",
                                 "args":[

                                 ],
                                 "kwargs":{
                                    "kwargs":{
                                       "kwargs":{
                                          "kwargs":{
                                             "kwargs":{
                                                "kwargs":{

                                                }
                                             }
                                          }
                                       }
                                    },
                                    "header":{
                                       "task":"celery.group",
                                       "args":[

                                       ],
                                       "kwargs":{
                                          "tasks":[
                                             {
                                                "task":"t.unit.tasks.test_canvas.echo",
                                                "args":[

                                                ],
                                                "kwargs":{
                                                   "name":"111"
                                                },
                                                "options":{
                                                   "task_id":"82bca28e-7728-4d28-a0ff-4c115598ed15",
                                                   "reply_to":"82c887bc-f3b2-307d-b887-6bcda4c207d8",
                                                   "chord":{
                                                      "task":"t.unit.tasks.test_canvas.echo",
                                                      "args":[

                                                      ],
                                                      "kwargs":{
                                                         "name":"11_"
                                                      },
                                                      "options":{
                                                         "task_id":"de8314ab-6335-4e31-8aba-5b2d21cefae0",
                                                         "reply_to":"82c887bc-f3b2-307d-b887-6bcda4c207d8"
                                                      },
                                                      "subtask_type":null,
                                                      "chord_size":null,
                                                      "immutable":true
                                                   }
                                                },
                                                "subtask_type":null,
                                                "chord_size":null,
                                                "immutable":true
                                             },
                                             {
                                                "task":"t.unit.tasks.test_canvas.echo",
                                                "args":[

                                                ],
                                                "kwargs":{
                                                   "name":"112"
                                                },
                                                "options":{
                                                   "task_id":"350f0c80-51aa-453b-afb1-43d5351b61ea",
                                                   "reply_to":"82c887bc-f3b2-307d-b887-6bcda4c207d8",
                                                   "chord":{
                                                      "task":"t.unit.tasks.test_canvas.echo",
                                                      "args":[

                                                      ],
                                                      "kwargs":{
                                                         "name":"11_"
                                                      },
                                                      "options":{
                                                         "task_id":"de8314ab-6335-4e31-8aba-5b2d21cefae0",
                                                         "reply_to":"82c887bc-f3b2-307d-b887-6bcda4c207d8"
                                                      },
                                                      "subtask_type":null,
                                                      "chord_size":null,
                                                      "immutable":true
                                                   }
                                                },
                                                "subtask_type":null,
                                                "chord_size":null,
                                                "immutable":true
                                             }
                                          ]
                                       },
                                       "options":{
                                          "task_id":"b7c47af1-b38b-412a-a0d0-233d3a042ab1",
                                          "chord":{
                                             "task":"t.unit.tasks.test_canvas.echo",
                                             "args":[

                                             ],
                                             "kwargs":{
                                                "name":"11_"
                                             },
                                             "options":{
                                                "task_id":"de8314ab-6335-4e31-8aba-5b2d21cefae0",
                                                "reply_to":"82c887bc-f3b2-307d-b887-6bcda4c207d8"
                                             },
                                             "subtask_type":null,
                                             "chord_size":null,
                                             "immutable":true
                                          },
                                          "root_id":null,
                                          "parent_id":null
                                       },
                                       "subtask_type":"group",
                                       "immutable":false,
                                       "chord_size":null
                                    },
                                    "body":{
                                       "task":"t.unit.tasks.test_canvas.echo",
                                       "args":[

                                       ],
                                       "kwargs":{
                                          "name":"11_"
                                       },
                                       "options":{
                                          "task_id":"de8314ab-6335-4e31-8aba-5b2d21cefae0",
                                          "reply_to":"82c887bc-f3b2-307d-b887-6bcda4c207d8"
                                       },
                                       "subtask_type":null,
                                       "chord_size":null,
                                       "immutable":true
                                    }
                                 },
                                 "options":{
                                    "chord_size":null,
                                    "task_id":"b7c47af1-b38b-412a-a0d0-233d3a042ab1"
                                 },
                                 "subtask_type":"chord",
                                 "immutable":false,
                                 "chord_size":null
                              },
                              {
                                 "task":"celery.chord",
                                 "args":[

                                 ],
                                 "kwargs":{
                                    "kwargs":{
                                       "kwargs":{
                                          "kwargs":{
                                             "kwargs":{
                                                "kwargs":{

                                                }
                                             }
                                          }
                                       }
                                    },
                                    "header":{
                                       "task":"celery.group",
                                       "args":[

                                       ],
                                       "kwargs":{
                                          "tasks":[
                                             {
                                                "task":"t.unit.tasks.test_canvas.echo",
                                                "args":[

                                                ],
                                                "kwargs":{
                                                   "name":"121"
                                                },
                                                "options":{
                                                   "task_id":"85d81a67-ac3d-494e-8ebc-97cb4db3b1dc",
                                                   "reply_to":"82c887bc-f3b2-307d-b887-6bcda4c207d8",
                                                   "chord":{
                                                      "task":"t.unit.tasks.test_canvas.echo",
                                                      "args":[

                                                      ],
                                                      "kwargs":{
                                                         "name":"12_"
                                                      },
                                                      "options":{
                                                         "task_id":"636ba9df-e5b9-4fc7-aa2a-5a05ff34359f",
                                                         "reply_to":"82c887bc-f3b2-307d-b887-6bcda4c207d8"
                                                      },
                                                      "subtask_type":null,
                                                      "chord_size":null,
                                                      "immutable":true
                                                   }
                                                },
                                                "subtask_type":null,
                                                "chord_size":null,
                                                "immutable":true
                                             },
                                             {
                                                "task":"t.unit.tasks.test_canvas.echo",
                                                "args":[

                                                ],
                                                "kwargs":{
                                                   "name":"122"
                                                },
                                                "options":{
                                                   "task_id":"2bd651f8-f715-4b2a-8bab-5b1adbf188dc",
                                                   "reply_to":"82c887bc-f3b2-307d-b887-6bcda4c207d8",
                                                   "chord":{
                                                      "task":"t.unit.tasks.test_canvas.echo",
                                                      "args":[

                                                      ],
                                                      "kwargs":{
                                                         "name":"12_"
                                                      },
                                                      "options":{
                                                         "task_id":"636ba9df-e5b9-4fc7-aa2a-5a05ff34359f",
                                                         "reply_to":"82c887bc-f3b2-307d-b887-6bcda4c207d8"
                                                      },
                                                      "subtask_type":null,
                                                      "chord_size":null,
                                                      "immutable":true
                                                   }
                                                },
                                                "subtask_type":null,
                                                "chord_size":null,
                                                "immutable":true
                                             }
                                          ]
                                       },
                                       "options":{
                                          "task_id":"372f929d-0c9e-43e7-adab-f04b5bfb2918",
                                          "chord":{
                                             "task":"t.unit.tasks.test_canvas.echo",
                                             "args":[

                                             ],
                                             "kwargs":{
                                                "name":"12_"
                                             },
                                             "options":{
                                                "task_id":"636ba9df-e5b9-4fc7-aa2a-5a05ff34359f",
                                                "reply_to":"82c887bc-f3b2-307d-b887-6bcda4c207d8"
                                             },
                                             "subtask_type":null,
                                             "chord_size":null,
                                             "immutable":true
                                          },
                                          "root_id":null,
                                          "parent_id":null
                                       },
                                       "subtask_type":"group",
                                       "immutable":false,
                                       "chord_size":null
                                    },
                                    "body":{
                                       "task":"t.unit.tasks.test_canvas.echo",
                                       "args":[

                                       ],
                                       "kwargs":{
                                          "name":"12_"
                                       },
                                       "options":{
                                          "task_id":"636ba9df-e5b9-4fc7-aa2a-5a05ff34359f",
                                          "reply_to":"82c887bc-f3b2-307d-b887-6bcda4c207d8"
                                       },
                                       "subtask_type":null,
                                       "chord_size":null,
                                       "immutable":true
                                    }
                                 },
                                 "options":{
                                    "chord_size":null,
                                    "task_id":"372f929d-0c9e-43e7-adab-f04b5bfb2918"
                                 },
                                 "subtask_type":"chord",
                                 "immutable":false,
                                 "chord_size":null
                              }
                           ]
                        },
                        "options":{
                           "task_id":"a78a1b2c-1976-4c79-aa2e-0f416dcb86be",
                           "chord":{
                              "task":"t.unit.tasks.test_canvas.echo",
                              "args":[

                              ],
                              "kwargs":{
                                 "name":"1_end"
                              },
                              "options":{
                                 "task_id":"9ad0471e-4661-4308-905a-09110f37c685",
                                 "reply_to":"82c887bc-f3b2-307d-b887-6bcda4c207d8"
                              },
                              "subtask_type":null,
                              "chord_size":null,
                              "immutable":true
                           },
                           "root_id":null,
                           "parent_id":null
                        },
                        "subtask_type":"group",
                        "immutable":false,
                        "chord_size":null
                     },
                     "body":{
                        "task":"t.unit.tasks.test_canvas.echo",
                        "args":[

                        ],
                        "kwargs":{
                           "name":"1_end"
                        },
                        "options":{
                           "task_id":"9ad0471e-4661-4308-905a-09110f37c685",
                           "reply_to":"82c887bc-f3b2-307d-b887-6bcda4c207d8"
                        },
                        "subtask_type":null,
                        "chord_size":null,
                        "immutable":true
                     }
                  },
                  "options":{
                     "chord_size":null,
                     "task_id":"a78a1b2c-1976-4c79-aa2e-0f416dcb86be"
                  },
                  "subtask_type":"chord",
                  "immutable":false,
                  "chord_size":null
               },
               {
                  "task":"celery.chord",
                  "args":[

                  ],
                  "kwargs":{
                     "kwargs":{
                        "kwargs":{
                           "kwargs":{

                           }
                        }
                     },
                     "header":{
                        "task":"celery.group",
                        "args":[

                        ],
                        "kwargs":{
                           "tasks":[
                              {
                                 "task":"celery.chord",
                                 "args":[

                                 ],
                                 "kwargs":{
                                    "kwargs":{
                                       "kwargs":{
                                          "kwargs":{
                                             "kwargs":{
                                                "kwargs":{

                                                }
                                             }
                                          }
                                       }
                                    },
                                    "header":{
                                       "task":"celery.group",
                                       "args":[

                                       ],
                                       "kwargs":{
                                          "tasks":[
                                             {
                                                "task":"t.unit.tasks.test_canvas.echo",
                                                "args":[

                                                ],
                                                "kwargs":{
                                                   "name":"211"
                                                },
                                                "options":{
                                                   "task_id":"eee62431-3d90-4f01-a6e7-88624e448702",
                                                   "reply_to":"82c887bc-f3b2-307d-b887-6bcda4c207d8",
                                                   "chord":{
                                                      "task":"t.unit.tasks.test_canvas.echo",
                                                      "args":[

                                                      ],
                                                      "kwargs":{
                                                         "name":"21_"
                                                      },
                                                      "options":{
                                                         "task_id":"2943fd6b-4e8b-4740-9199-3fa2d2adf9b0",
                                                         "reply_to":"82c887bc-f3b2-307d-b887-6bcda4c207d8"
                                                      },
                                                      "subtask_type":null,
                                                      "chord_size":null,
                                                      "immutable":true
                                                   }
                                                },
                                                "subtask_type":null,
                                                "chord_size":null,
                                                "immutable":true
                                             },
                                             {
                                                "task":"t.unit.tasks.test_canvas.echo",
                                                "args":[

                                                ],
                                                "kwargs":{
                                                   "name":"212"
                                                },
                                                "options":{
                                                   "task_id":"79f3ae2b-3d04-4a2d-9b83-069926d9fda7",
                                                   "reply_to":"82c887bc-f3b2-307d-b887-6bcda4c207d8",
                                                   "chord":{
                                                      "task":"t.unit.tasks.test_canvas.echo",
                                                      "args":[

                                                      ],
                                                      "kwargs":{
                                                         "name":"21_"
                                                      },
                                                      "options":{
                                                         "task_id":"2943fd6b-4e8b-4740-9199-3fa2d2adf9b0",
                                                         "reply_to":"82c887bc-f3b2-307d-b887-6bcda4c207d8"
                                                      },
                                                      "subtask_type":null,
                                                      "chord_size":null,
                                                      "immutable":true
                                                   }
                                                },
                                                "subtask_type":null,
                                                "chord_size":null,
                                                "immutable":true
                                             }
                                          ]
                                       },
                                       "options":{
                                          "task_id":"fc52502a-e03f-41dd-ab2a-545987966de8",
                                          "chord":{
                                             "task":"t.unit.tasks.test_canvas.echo",
                                             "args":[

                                             ],
                                             "kwargs":{
                                                "name":"21_"
                                             },
                                             "options":{
                                                "task_id":"2943fd6b-4e8b-4740-9199-3fa2d2adf9b0",
                                                "reply_to":"82c887bc-f3b2-307d-b887-6bcda4c207d8"
                                             },
                                             "subtask_type":null,
                                             "chord_size":null,
                                             "immutable":true
                                          },
                                          "root_id":null,
                                          "parent_id":null
                                       },
                                       "subtask_type":"group",
                                       "immutable":false,
                                       "chord_size":null
                                    },
                                    "body":{
                                       "task":"t.unit.tasks.test_canvas.echo",
                                       "args":[

                                       ],
                                       "kwargs":{
                                          "name":"21_"
                                       },
                                       "options":{
                                          "task_id":"2943fd6b-4e8b-4740-9199-3fa2d2adf9b0",
                                          "reply_to":"82c887bc-f3b2-307d-b887-6bcda4c207d8"
                                       },
                                       "subtask_type":null,
                                       "chord_size":null,
                                       "immutable":true
                                    }
                                 },
                                 "options":{
                                    "chord_size":null,
                                    "task_id":"fc52502a-e03f-41dd-ab2a-545987966de8"
                                 },
                                 "subtask_type":"chord",
                                 "immutable":false,
                                 "chord_size":null
                              },
                              {
                                 "task":"celery.chord",
                                 "args":[

                                 ],
                                 "kwargs":{
                                    "kwargs":{
                                       "kwargs":{
                                          "kwargs":{
                                             "kwargs":{
                                                "kwargs":{

                                                }
                                             }
                                          }
                                       }
                                    },
                                    "header":{
                                       "task":"celery.group",
                                       "args":[

                                       ],
                                       "kwargs":{
                                          "tasks":[
                                             {
                                                "task":"t.unit.tasks.test_canvas.echo",
                                                "args":[

                                                ],
                                                "kwargs":{
                                                   "name":"221"
                                                },
                                                "options":{
                                                   "task_id":"d5ac9624-4eee-4338-936f-d1a9b11dcfa8",
                                                   "reply_to":"82c887bc-f3b2-307d-b887-6bcda4c207d8",
                                                   "chord":{
                                                      "task":"t.unit.tasks.test_canvas.echo",
                                                      "args":[

                                                      ],
                                                      "kwargs":{
                                                         "name":"22_"
                                                      },
                                                      "options":{
                                                         "task_id":"0b28fc04-e52e-43c9-8d7b-5079f6e1c8bb",
                                                         "reply_to":"82c887bc-f3b2-307d-b887-6bcda4c207d8"
                                                      },
                                                      "subtask_type":null,
                                                      "chord_size":null,
                                                      "immutable":true
                                                   }
                                                },
                                                "subtask_type":null,
                                                "chord_size":null,
                                                "immutable":true
                                             },
                                             {
                                                "task":"t.unit.tasks.test_canvas.echo",
                                                "args":[

                                                ],
                                                "kwargs":{
                                                   "name":"222"
                                                },
                                                "options":{
                                                   "task_id":"8fed913a-5e91-4c96-a24f-9ce9fa02d6d8",
                                                   "reply_to":"82c887bc-f3b2-307d-b887-6bcda4c207d8",
                                                   "chord":{
                                                      "task":"t.unit.tasks.test_canvas.echo",
                                                      "args":[

                                                      ],
                                                      "kwargs":{
                                                         "name":"22_"
                                                      },
                                                      "options":{
                                                         "task_id":"0b28fc04-e52e-43c9-8d7b-5079f6e1c8bb",
                                                         "reply_to":"82c887bc-f3b2-307d-b887-6bcda4c207d8"
                                                      },
                                                      "subtask_type":null,
                                                      "chord_size":null,
                                                      "immutable":true
                                                   }
                                                },
                                                "subtask_type":null,
                                                "chord_size":null,
                                                "immutable":true
                                             }
                                          ]
                                       },
                                       "options":{
                                          "task_id":"15031b97-b6ba-4bd8-b9b8-6b2bea5c2b5e",
                                          "chord":{
                                             "task":"t.unit.tasks.test_canvas.echo",
                                             "args":[

                                             ],
                                             "kwargs":{
                                                "name":"22_"
                                             },
                                             "options":{
                                                "task_id":"0b28fc04-e52e-43c9-8d7b-5079f6e1c8bb",
                                                "reply_to":"82c887bc-f3b2-307d-b887-6bcda4c207d8"
                                             },
                                             "subtask_type":null,
                                             "chord_size":null,
                                             "immutable":true
                                          },
                                          "root_id":null,
                                          "parent_id":null
                                       },
                                       "subtask_type":"group",
                                       "immutable":false,
                                       "chord_size":null
                                    },
                                    "body":{
                                       "task":"t.unit.tasks.test_canvas.echo",
                                       "args":[

                                       ],
                                       "kwargs":{
                                          "name":"22_"
                                       },
                                       "options":{
                                          "task_id":"0b28fc04-e52e-43c9-8d7b-5079f6e1c8bb",
                                          "reply_to":"82c887bc-f3b2-307d-b887-6bcda4c207d8"
                                       },
                                       "subtask_type":null,
                                       "chord_size":null,
                                       "immutable":true
                                    }
                                 },
                                 "options":{
                                    "chord_size":null,
                                    "task_id":"15031b97-b6ba-4bd8-b9b8-6b2bea5c2b5e"
                                 },
                                 "subtask_type":"chord",
                                 "immutable":false,
                                 "chord_size":null
                              }
                           ]
                        },
                        "options":{
                           "task_id":"ef0ed999-cc9b-4cf4-a183-078bcf5875c6",
                           "chord":{
                              "task":"t.unit.tasks.test_canvas.echo",
                              "args":[

                              ],
                              "kwargs":{
                                 "name":"2_end"
                              },
                              "options":{
                                 "task_id":"306eed60-7ad1-414a-a08c-0ab2eb842b60",
                                 "reply_to":"82c887bc-f3b2-307d-b887-6bcda4c207d8"
                              },
                              "subtask_type":null,
                              "chord_size":null,
                              "immutable":true
                           },
                           "root_id":null,
                           "parent_id":null
                        },
                        "subtask_type":"group",
                        "immutable":false,
                        "chord_size":null
                     },
                     "body":{
                        "task":"t.unit.tasks.test_canvas.echo",
                        "args":[

                        ],
                        "kwargs":{
                           "name":"2_end"
                        },
                        "options":{
                           "task_id":"306eed60-7ad1-414a-a08c-0ab2eb842b60",
                           "reply_to":"82c887bc-f3b2-307d-b887-6bcda4c207d8"
                        },
                        "subtask_type":null,
                        "chord_size":null,
                        "immutable":true
                     }
                  },
                  "options":{
                     "chord_size":null,
                     "task_id":"ef0ed999-cc9b-4cf4-a183-078bcf5875c6"
                  },
                  "subtask_type":"chord",
                  "immutable":false,
                  "chord_size":null
               },
               {
                  "task":"celery.chord",
                  "args":[

                  ],
                  "kwargs":{
                     "kwargs":{
                        "kwargs":{
                           "kwargs":{

                           }
                        }
                     },
                     "header":{
                        "task":"celery.group",
                        "args":[

                        ],
                        "kwargs":{
                           "tasks":[
                              {
                                 "task":"celery.chord",
                                 "args":[

                                 ],
                                 "kwargs":{
                                    "kwargs":{
                                       "kwargs":{
                                          "kwargs":{
                                             "kwargs":{
                                                "kwargs":{

                                                }
                                             }
                                          }
                                       }
                                    },
                                    "header":{
                                       "task":"celery.group",
                                       "args":[

                                       ],
                                       "kwargs":{
                                          "tasks":[
                                             {
                                                "task":"t.unit.tasks.test_canvas.echo",
                                                "args":[

                                                ],
                                                "kwargs":{
                                                   "name":"311"
                                                },
                                                "options":{
                                                   "task_id":"5f15eef5-d451-456d-b38c-ae3a83f06951",
                                                   "reply_to":"82c887bc-f3b2-307d-b887-6bcda4c207d8",
                                                   "chord":{
                                                      "task":"t.unit.tasks.test_canvas.echo",
                                                      "args":[

                                                      ],
                                                      "kwargs":{
                                                         "name":"31_"
                                                      },
                                                      "options":{
                                                         "task_id":"6dc50b9f-436d-40aa-9827-f702e6a25efc",
                                                         "reply_to":"82c887bc-f3b2-307d-b887-6bcda4c207d8"
                                                      },
                                                      "subtask_type":null,
                                                      "chord_size":null,
                                                      "immutable":true
                                                   }
                                                },
                                                "subtask_type":null,
                                                "chord_size":null,
                                                "immutable":true
                                             },
                                             {
                                                "task":"t.unit.tasks.test_canvas.echo",
                                                "args":[

                                                ],
                                                "kwargs":{
                                                   "name":"312"
                                                },
                                                "options":{
                                                   "task_id":"d2cd90cd-9bd2-4dcb-8e26-3676b09111e1",
                                                   "reply_to":"82c887bc-f3b2-307d-b887-6bcda4c207d8",
                                                   "chord":{
                                                      "task":"t.unit.tasks.test_canvas.echo",
                                                      "args":[

                                                      ],
                                                      "kwargs":{
                                                         "name":"31_"
                                                      },
                                                      "options":{
                                                         "task_id":"6dc50b9f-436d-40aa-9827-f702e6a25efc",
                                                         "reply_to":"82c887bc-f3b2-307d-b887-6bcda4c207d8"
                                                      },
                                                      "subtask_type":null,
                                                      "chord_size":null,
                                                      "immutable":true
                                                   }
                                                },
                                                "subtask_type":null,
                                                "chord_size":null,
                                                "immutable":true
                                             }
                                          ]
                                       },
                                       "options":{
                                          "task_id":"c9595837-b9a5-487f-ac3e-77fc4c9df876",
                                          "chord":{
                                             "task":"t.unit.tasks.test_canvas.echo",
                                             "args":[

                                             ],
                                             "kwargs":{
                                                "name":"31_"
                                             },
                                             "options":{
                                                "task_id":"6dc50b9f-436d-40aa-9827-f702e6a25efc",
                                                "reply_to":"82c887bc-f3b2-307d-b887-6bcda4c207d8"
                                             },
                                             "subtask_type":null,
                                             "chord_size":null,
                                             "immutable":true
                                          },
                                          "root_id":null,
                                          "parent_id":null
                                       },
                                       "subtask_type":"group",
                                       "immutable":false,
                                       "chord_size":null
                                    },
                                    "body":{
                                       "task":"t.unit.tasks.test_canvas.echo",
                                       "args":[

                                       ],
                                       "kwargs":{
                                          "name":"31_"
                                       },
                                       "options":{
                                          "task_id":"6dc50b9f-436d-40aa-9827-f702e6a25efc",
                                          "reply_to":"82c887bc-f3b2-307d-b887-6bcda4c207d8"
                                       },
                                       "subtask_type":null,
                                       "chord_size":null,
                                       "immutable":true
                                    }
                                 },
                                 "options":{
                                    "chord_size":null,
                                    "task_id":"c9595837-b9a5-487f-ac3e-77fc4c9df876"
                                 },
                                 "subtask_type":"chord",
                                 "immutable":false,
                                 "chord_size":null
                              },
                              {
                                 "task":"celery.chord",
                                 "args":[

                                 ],
                                 "kwargs":{
                                    "kwargs":{
                                       "kwargs":{
                                          "kwargs":{
                                             "kwargs":{
                                                "kwargs":{

                                                }
                                             }
                                          }
                                       }
                                    },
                                    "header":{
                                       "task":"celery.group",
                                       "args":[

                                       ],
                                       "kwargs":{
                                          "tasks":[
                                             {
                                                "task":"t.unit.tasks.test_canvas.echo",
                                                "args":[

                                                ],
                                                "kwargs":{
                                                   "name":"321"
                                                },
                                                "options":{
                                                   "task_id":"660cf95e-4d66-4d53-bdb0-f1e7854b6273",
                                                   "reply_to":"82c887bc-f3b2-307d-b887-6bcda4c207d8",
                                                   "chord":{
                                                      "task":"t.unit.tasks.test_canvas.echo",
                                                      "args":[

                                                      ],
                                                      "kwargs":{
                                                         "name":"32_"
                                                      },
                                                      "options":{
                                                         "task_id":"ab8bf961-7a87-4244-b8e9-77d0289133a8",
                                                         "reply_to":"82c887bc-f3b2-307d-b887-6bcda4c207d8"
                                                      },
                                                      "subtask_type":null,
                                                      "chord_size":null,
                                                      "immutable":true
                                                   }
                                                },
                                                "subtask_type":null,
                                                "chord_size":null,
                                                "immutable":true
                                             },
                                             {
                                                "task":"t.unit.tasks.test_canvas.echo",
                                                "args":[

                                                ],
                                                "kwargs":{
                                                   "name":"322"
                                                },
                                                "options":{
                                                   "task_id":"8ced55b5-6778-465e-900a-d089b7084b75",
                                                   "reply_to":"82c887bc-f3b2-307d-b887-6bcda4c207d8",
                                                   "chord":{
                                                      "task":"t.unit.tasks.test_canvas.echo",
                                                      "args":[

                                                      ],
                                                      "kwargs":{
                                                         "name":"32_"
                                                      },
                                                      "options":{
                                                         "task_id":"ab8bf961-7a87-4244-b8e9-77d0289133a8",
                                                         "reply_to":"82c887bc-f3b2-307d-b887-6bcda4c207d8"
                                                      },
                                                      "subtask_type":null,
                                                      "chord_size":null,
                                                      "immutable":true
                                                   }
                                                },
                                                "subtask_type":null,
                                                "chord_size":null,
                                                "immutable":true
                                             }
                                          ]
                                       },
                                       "options":{
                                          "task_id":"0d834a40-cb2b-4255-b819-039a393df493",
                                          "chord":{
                                             "task":"t.unit.tasks.test_canvas.echo",
                                             "args":[

                                             ],
                                             "kwargs":{
                                                "name":"32_"
                                             },
                                             "options":{
                                                "task_id":"ab8bf961-7a87-4244-b8e9-77d0289133a8",
                                                "reply_to":"82c887bc-f3b2-307d-b887-6bcda4c207d8"
                                             },
                                             "subtask_type":null,
                                             "chord_size":null,
                                             "immutable":true
                                          },
                                          "root_id":null,
                                          "parent_id":null
                                       },
                                       "subtask_type":"group",
                                       "immutable":false,
                                       "chord_size":null
                                    },
                                    "body":{
                                       "task":"t.unit.tasks.test_canvas.echo",
                                       "args":[

                                       ],
                                       "kwargs":{
                                          "name":"32_"
                                       },
                                       "options":{
                                          "task_id":"ab8bf961-7a87-4244-b8e9-77d0289133a8",
                                          "reply_to":"82c887bc-f3b2-307d-b887-6bcda4c207d8"
                                       },
                                       "subtask_type":null,
                                       "chord_size":null,
                                       "immutable":true
                                    }
                                 },
                                 "options":{
                                    "chord_size":null,
                                    "task_id":"0d834a40-cb2b-4255-b819-039a393df493"
                                 },
                                 "subtask_type":"chord",
                                 "immutable":false,
                                 "chord_size":null
                              }
                           ]
                        },
                        "options":{
                           "task_id":"685e76f6-0da4-4f92-bff4-58a8451c9bef",
                           "chord":{
                              "task":"t.unit.tasks.test_canvas.echo",
                              "args":[

                              ],
                              "kwargs":{
                                 "name":"3_end"
                              },
                              "options":{
                                 "task_id":"103c3241-c210-4453-bd77-2ba527d6b804",
                                 "reply_to":"82c887bc-f3b2-307d-b887-6bcda4c207d8"
                              },
                              "subtask_type":null,
                              "chord_size":null,
                              "immutable":true
                           },
                           "root_id":null,
                           "parent_id":null
                        },
                        "subtask_type":"group",
                        "immutable":false,
                        "chord_size":null
                     },
                     "body":{
                        "task":"t.unit.tasks.test_canvas.echo",
                        "args":[

                        ],
                        "kwargs":{
                           "name":"3_end"
                        },
                        "options":{
                           "task_id":"103c3241-c210-4453-bd77-2ba527d6b804",
                           "reply_to":"82c887bc-f3b2-307d-b887-6bcda4c207d8"
                        },
                        "subtask_type":null,
                        "chord_size":null,
                        "immutable":true
                     }
                  },
                  "options":{
                     "chord_size":null,
                     "task_id":"685e76f6-0da4-4f92-bff4-58a8451c9bef"
                  },
                  "subtask_type":"chord",
                  "immutable":false,
                  "chord_size":null
               }
            ]
         },
         "options":{
            "task_id":"1fee6d2c-40f7-4f8b-bd60-e763535ba28f",
            "chord":{
               "task":"t.unit.tasks.test_canvas.echo",
               "args":[

               ],
               "kwargs":{
                  "name":"end"
               },
               "options":{
                  "task_id":"0de72cdf-4c16-4011-bd59-4c4b02be6440",
                  "reply_to":"82c887bc-f3b2-307d-b887-6bcda4c207d8"
               },
               "subtask_type":null,
               "immutable":true,
               "chord_size":null
            },
            "root_id":null,
            "parent_id":null
         },
         "subtask_type":"group",
         "immutable":false,
         "chord_size":null
      },
      "body":{
         "task":"t.unit.tasks.test_canvas.echo",
         "args":[

         ],
         "kwargs":{
            "name":"end"
         },
         "options":{
            "task_id":"0de72cdf-4c16-4011-bd59-4c4b02be6440",
            "reply_to":"82c887bc-f3b2-307d-b887-6bcda4c207d8"
         },
         "subtask_type":null,
         "immutable":true,
         "chord_size":null
      }
   },
   "options":{
      "task_id":"1fee6d2c-40f7-4f8b-bd60-e763535ba28f"
   },
   "subtask_type":"chord",
   "immutable":false,
   "chord_size":null
}

This is the json I get from the chord you provided. It's completely different so I'm wondering where you got it from.

@auvipy

auvipy commented Dec 12, 2017

Copy link
Copy Markdown
Member

hi @zpl could you check if this resolve your issue?
#4437

@auvipy auvipy closed this Dec 12, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants