Uploaded image for project: 'SR for Jira - Development'
  1. SR for Jira - Development
  2. SRJIRA-4472

jiraHelper variable is unrecognized causing the Script Fragment to fail

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Triage
    • Priority: Major
    • Resolution: Unresolved
    • Affects Version/s: 5.6.14.1-p5, 6.3.0
    • Fix Version/s: None
    • Component/s: Fragments
    • Labels:
      None
    • Critical Points:
      2.8

      Description

      Steps to reproduce:

      1. Make a "Hide system or plugin UI element" script fragment that hides anything. Use the "com.atlassian.jira.jira-projects-plugin:browse-project-activity-stream" to hide the Activity view in the Project Summary
      2. Use a condition like:
        jiraHelper.project?.key in ["FT"]
        
      3. Below is a print screen of the Script Fragment Configuration

      Current Behaviour

      1. When back to the Activity page, as expected the items are hidden as shown in
      2. Open an Activity page of another project, unexpectedly the items here are hidden as well as show in
      3. Also an exception is returned in the log saying that the jiraHelper is missing
        2020-06-30 16:30:59,382+0800 http-nio-9091-exec-6 ERROR admin 990x1535x1 sjvty1 0:0:0:0:0:0:0:1 /projects/FT/summary [c.o.scriptrunner.fragments.ScriptCondition] Script condition failed: 
        groovy.lang.MissingPropertyException: No such property: jiraHelper for class: Inline1038622920
        	at Inline1038622920.run(Inline1038622920.groovy:6)
        	at Inline1038622920$run.call(Unknown Source)
        	at Inline1551019382$run.call(Unknown Source)
        	at com.onresolve.scriptrunner.fragments.ScriptCondition.shouldDisplay(ScriptCondition.groovy:62)
        

        Attachments

        1. fragment_config.png
          fragment_config.png
          120 kB
        2. image1.png
          image1.png
          75 kB
        3. image2.png
          image2.png
          74 kB

          Activity

            People

            Assignee:
            Unassigned Unassigned
            Reporter:
            rkumar Ram Kumar Aravindakshan
            Votes:
            3 Vote for this issue
            Watchers:
            5 Start watching this issue

              Dates

              Created:
              Updated: