Task with wait-before resets context

Bug #1681562 reported by Winson Chan
This bug affects 1 person
Affects Status Importance Assigned to Milestone

Bug Description

The following workflow will go into an infinite loop if there's a wait-before in task2. The state of var1 is reset in task2 if there's a wait-before. If wait-before is removed, the value in var1 is saved correctly.

version: '2.0'

    type: direct
        var1: 0
        retries: 3
            - <% $.var1 %>
            - <% $.var2 %>
            action: std.noop
                - task1
            action: std.noop
                var1: <% $.var1 + 1 %>
                - task2
            wait-before: 3
            action: std.echo
                output: <% $.var1 %>
                var2: <% task(task2).result %>
                - task1: <% $.var1 <= $.retries %>

Revision history for this message
Winson Chan (winson-c-chan) wrote :

It seems like the use of the cache @ https://github.com/openstack/mistral/blob/master/mistral/workflow/lookup_utils.py#L62 to get upstream task executions leads to getting the wrong in_context.

Dougal Matthews (d0ugal)
Changed in mistral:
status: New → Confirmed
importance: Undecided → Medium
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.