malformed json when result is transferred to state_info
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Mistral |
Fix Released
|
Medium
|
Hardik Jasani |
Bug Description
Given a dict in the task result, the double quotes are removed from the state info leading to a malformed json.
vagrant@
{
"error": "Execution canceled by user."
}
vagrant@
+------
| Field | Value |
+------
| ID | 24231044-
| Name | task1 |
| Workflow name | examples.
| Execution ID | 19d2e289-
| State | ERROR |
| State info | {error: Execution canceled by user.} |
| Created at | 2017-02-06 22:01:45 |
| Updated at | 2017-02-06 22:01:49 |
+------
Changed in mistral: | |
importance: | Undecided → Medium |
assignee: | nobody → Anastasia Kuznetsova (akuznetsova) |
Changed in mistral: | |
milestone: | none → pike-1 |
Changed in mistral: | |
milestone: | pike-1 → pike-2 |
Changed in mistral: | |
milestone: | pike-2 → pike-3 |
Changed in mistral: | |
milestone: | pike-3 → queens-1 |
Changed in mistral: | |
assignee: | Anastasia Kuznetsova (akuznetsova) → noa (noa-koffman) |
Changed in mistral: | |
milestone: | queens-1 → queens-2 |
Changed in mistral: | |
milestone: | queens-2 → queens-3 |
Changed in mistral: | |
assignee: | noa (noa-koffman) → Hardik Jasani (hjasani) |
Changed in mistral: | |
milestone: | queens-3 → queens-rc1 |
Changed in mistral: | |
status: | New → In Progress |
Changed in mistral: | |
milestone: | queens-rc1 → queens-rc2 |
Changed in mistral: | |
milestone: | queens-rc2 → rocky-1 |
tags: | added: queens-backport |
Hello Winson,
Can you help me a little bit?
I can't reproduce such case:
- I can get result in a dict format, but task status is SUCCESS and state_info is None
- I can reproduce situation when task status is ERROR, but state_info is not a dict.
So I am trying to use CANCEL feature like you've used, I think.
Here is my wf:
---
version: "2.0"
wf: ending_ task:
type: direct
tasks:
never_
action: std.sleep seconds=60
I do following:
mistral workflow-create wf.yaml
mistral execution-create wf
mistral execution-update -s CANCELLED <id>
Wf goes to CANCELLED status, but TASK is still RUNNING, so I can't get message like in the description. As for me it looks like a bug.
Could you please provide your steps?