Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-73894

[warnings-ng] Un-inline JavaScript in IssuesChartPortlet/portlet.jelly

    • 11.10.0

      Culprit

      https://github.com/jenkinsci/warnings-ng-plugin/blob/e659c7ada2792573a475e50242ef4c9d9bdb9b85/plugin/src/main/resources/io/jenkins/plugins/analysis/core/portlets/IssuesChartPortlet/portlet.jelly#L18-L24

      Solution

      Use st:bind with var attribute to define a global variable, which can then be accessed from JavaScript. Use data attributes with e.g. span element to pass whatever other data is needed.
      (No docs exist AFAICT? Perhaps we could improve here )

          [JENKINS-73894] [warnings-ng] Un-inline JavaScript in IssuesChartPortlet/portlet.jelly

          I'm not entirely sure I've identified the culprit correctly. The failing ATH test is https://ci.jenkins.io/job/Core/job/acceptance-test-harness/job/PR-1749/7/testReport/plugins/XUnitPluginTest/latest_linux_jdk21_firefox_split9___publish_xunit_results/

          Searching the org for const trendProxy points to the location I've linked in the description of the issue.

          Yaroslav Afenkin added a comment - I'm not entirely sure I've identified the culprit correctly. The failing ATH test is https://ci.jenkins.io/job/Core/job/acceptance-test-harness/job/PR-1749/7/testReport/plugins/XUnitPluginTest/latest_linux_jdk21_firefox_split9___publish_xunit_results/ Searching the org for const trendProxy points to the location I've linked in the description of the issue.

          Basil Crow added a comment -

          Basil Crow added a comment - Fixed in https://github.com/jenkinsci/warnings-ng-plugin/pull/1859 . Released in 11.10.0 .

            yafenkin Yaroslav Afenkin
            yafenkin Yaroslav Afenkin
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: