-
Bug
-
Resolution: Not a bug
-
Low
-
1
-
Severity 3 - Minor
-
Issue Summary
Any variable outside branch (before) is required to access the value of any variable created inside a branch after the branch execution ended.
Steps to Reproduce
- Create a variable inside the branch
- Access the value outside the branch. It's only accessible if any other variable was created before the branch even if it's not used.
Expected Results
Either no variable should be required before the branch, or it should be the same variable that requires to be created before the branch (global context)
Actual Results
If no variable is created before the branch then the variables created inside the branch context cannot be used outside the branch.
Workaround
create any variable before the branch
[JSWCLOUD-22527] It's required to create any variable before branch to access a variable created inside branch after the branch execution ended
Component/s | Original: Jira Platform - Automation [ 60591 ] | |
Component/s | New: Automation [ 68402 ] | |
Key |
Original:
|
New:
|
Project | Original: Jira Cloud [ 18514 ] | New: Jira Software Cloud [ 18511 ] |
Labels | New: Automation_Move_JSW |
Resolution | New: Not a bug [ 12 ] | |
Status | Original: Needs Triage [ 10030 ] | New: Closed [ 6 ] |
Support reference count | New: 1 |
Description |
Original:
h3. Issue Summary
Any variable outside branch (before) is required to access the value of any variable created inside a branch after the branch execution ended. h3. Steps to Reproduce # Create a variable inside the branch # Access the value outside the branch. It's only accessible if any other variable was created before the branch even if it's not used. h3. Expected Results Either no variable should be required before the branch, orit should be the same variable that requires to be created before the branch (global context) h3. Actual Results If no variable is created before the branch then the variables created inside the branch context cannot be used outside the branch. !image-2021-11-09-19-35-15-915.png|width=315,height=190! h3. Workaround create any variable before the branch |
New:
h3. Issue Summary
Any variable outside branch (before) is required to access the value of any variable created inside a branch after the branch execution ended. h3. Steps to Reproduce # Create a variable inside the branch # Access the value outside the branch. It's only accessible if any other variable was created before the branch even if it's not used. h3. Expected Results Either no variable should be required before the branch, or it should be the same variable that requires to be created before the branch (global context) h3. Actual Results If no variable is created before the branch then the variables created inside the branch context cannot be used outside the branch. !image-2021-11-09-19-35-15-915.png|width=315,height=190! h3. Workaround create any variable before the branch |
Description |
Original:
h3. Issue Summary
Any variable outside branch (before) is required to access the value of any variable created inside a branch after the branch execution ended. h3. Steps to Reproduce # Create a variable inside the branch # Access the value outside the branch. It's only accessible if any other variable was created before the branch even if it's not used. h3. Expected Results Either no variable should be required before the branch (or at least it should be the same variable that requires to be created before the branch) h3. Actual Results If no variable is created before the branch then the variables created inside the branch context cannot be used outside the branch. !image-2021-11-09-19-35-15-915.png|width=315,height=190! h3. Workaround create any variable before the branch |
New:
h3. Issue Summary
Any variable outside branch (before) is required to access the value of any variable created inside a branch after the branch execution ended. h3. Steps to Reproduce # Create a variable inside the branch # Access the value outside the branch. It's only accessible if any other variable was created before the branch even if it's not used. h3. Expected Results Either no variable should be required before the branch, orit should be the same variable that requires to be created before the branch (global context) h3. Actual Results If no variable is created before the branch then the variables created inside the branch context cannot be used outside the branch. !image-2021-11-09-19-35-15-915.png|width=315,height=190! h3. Workaround create any variable before the branch |
Summary | Original: Any variable before branch is required to access a variable created in branch after branch execution ended | New: It's required to create any variable before branch to access a variable created inside branch after the branch execution ended |
I am not sure what you mean by "parentvalue" in this context. The problem here is that any variables created inside the branch (or editing a variable previously declared outside the branch) do not reflect those changes in the rest of the rule after the branch component, except for one special case.
The one special case is if you declare any variable before the branch component, ONE branch execution will have its variable changes reflected in the rest of the rule. This branch is the first branch executed.
There are a bunch of technical reasons for this edge case, but this is not behaviour we would want customers relying on, as it is not intended user experience. We are in the process of looking at alternatives to fix this in a non-invasive way.
Cheers
Sam