Details
-
Bug
-
Resolution: Unresolved
-
Low
-
Minor
Description
Issue Summary
When you combine the use of a lookupIssues block and the diff function, when there are multiple issues, the diff function remembers the argument for the first issue, and uses it for all subsequent issues (rather their using the argument for each respective issue).
Steps to Reproduce
Create an automation rule with the following specs:
- Trigger: Scheduled
- Action1: Lookup Issues
- Lookup 2+ resolved issues (with different resolved times)
- Action2: Add "Log Action" action with this smart value:
-
{{#lookupIssues}} {{key}} From {{created}} till {{resolved}} --- {{created.diff(resolved)}} \\ {{/}}
Expected Results
SP-6 From 2023-02-07T06:53:00.0+0000 till 2023-02-07T07:31:12.6+0000 --- 38 minutes 12 seconds \\ SP-5 From 2023-02-07T06:52:44.9+0000 till 2023-02-07T06:53:04.1+0000 --- 0 minutes 20 seconds \\
Both diffs should be correct: 38m 12s, then 0m 20s.
h3. Actual Results
SP-6 From 2023-02-07T06:53:00.0+0000 till 2023-02-07T07:31:12.6+0000 --- 38 minutes 12 seconds \\
SP-5 From 2023-02-07T06:52:44.9+0000 till 2023-02-07T06:53:04.1+0000 --- 38 minutes 27 seconds \\
The 2nd (and subsequent diffs) are wrong. It shows 38m 12s, then 38m 27s.
The reason is that the diff function is using the resolvedDate from the first Issue (SP-6) instead of the resolvedDate from the current issue (SP-5).
Workaround
Currently there is no known workaround for this bug.