__env is not evaluated by with_items
Bug #1413338 reported by
Dmitri Zimine
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Mistral |
Fix Released
|
Medium
|
Nikolay Makhotkin | ||
Liberty |
Fix Released
|
Medium
|
Nikolay Makhotkin |
Bug Description
Bug:
_env is evaluated here,
https:/
but not here:
https:/
I think once we split the logic here,
- https:/
it leads to code and logic duplication is doomed to diverge. Thoughs on how to refactor it?
DZ>
Changed in mistral: | |
milestone: | none → kilo-2 |
importance: | Undecided → Medium |
status: | New → Confirmed |
Changed in mistral: | |
milestone: | kilo-2 → kilo-3 |
no longer affects: | mistral/kilo |
Changed in mistral: | |
milestone: | 1.0.0 → none |
To post a comment you must log in.
Can't reproduce:
1. Create workbook:
version: "2.0"
name: wb1
workflows:
with_items:
type: direct
input:
- names
tasks:
task1:
with-items: name in <% $.names %>
action: std.echo output="http://<% $.name %>! <% $.__env.adj %>"
2. Start execution: mistral execution-create wb1.with_items '{"names": [1, 2, 3]}' '{"env": {"adj": "Mistral"}}'
3. get the result:
$ mistral task-list dc8b2335- aa67-4a28- a734-5002a8db96 28
+------ ------- ------- ------- ------- ----+-- -----+- ------- ------- -+----- ------- ------- ------- ------- -----+- ------- -+ ------- ------- ------- ------- ----+-- -----+- ------- ------- -+----- ------- ------- ------- ------- -----+- ------- -+ f5a6-4aa0- a22c-57d88137c1 b7 | task1 | wb1.with_items | dc8b2335- aa67-4a28- a734-5002a8db96 28 | SUCCESS | ------- ------- ------- ------- ----+-- -----+- ------- ------- -+----- ------- ------- ------- ------- -----+- ------- -+ f5a6-4aa0- a22c-57d88137c1 b7
| ID | Name | Workflow name | Execution ID | State |
+------
| cf15aa56-
+------
$ mistral task-get-result cf15aa56-
[ 2! Mistral", 3! Mistral", 1! Mistral"
"http://
"http://
"http://
]