Uploaded image for project: 'Bamboo Data Center'
  1. Bamboo Data Center
  2. BAM-3757

After X Failed Notifications "Updated By" is broken.

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • Medium
    • 2.3
    • 2.3 M2
    • None
    • None

    Description

      Essentially the bug fix has caused and stacktrace to be thrown in notifications:

      Expression ww is undefined on line 2, column 7 in com/atlassian/bamboo/build/triggerReasons/codeChangedTriggerReason-short.ftl. The problematic instruction: ---------- ==> user-directive ww.text [on line 2, column 5 in com/atlassian/bamboo/build/triggerReasons/codeChangedTriggerReason-short.ftl] ---------- Java backtrace for programmers: ---------- freemarker.core.InvalidReferenceException: Expression ww is undefined on line 2, column 7 in com/atlassian/bamboo/build/triggerReasons/codeChangedTriggerReason-short.ftl. at freemarker.core.TemplateObject.assertNonNull(TemplateObject.java:124) at freemarker.core.TemplateObject.invalidTypeException(TemplateObject.java:134) at freemarker.core.Dot._getAsTemplateModel(Dot.java:78) at freemarker.core.Expression.getAsTemplateModel(Expression.java:89) at freemarker.core.UnifiedCall.accept(UnifiedCall.java:97) at freemarker.core.Environment.visit(Environment.java:209) at freemarker.core.MixedContent.accept(MixedContent.java:92) at freemarker.core.Environment.visit(Environment.java:209) at freemarker.core.IfBlock.accept(IfBlock.java:82) at freemarker.core.Environment.visit(Environment.java:209) at freemarker.core.Environment.process(Environment.java:189) at
      

      This effects both the html and text email templates for the after X failed builds (I would also check Instant Messages to).

      The problem: Notifications are generated from freemarker outside of a web context which means we have no access to anything provided by the web context. This includes anything in the webapp directory (eg macros). Which means you cannot use [@ww... in notifications including [@ww.text. All the trigger reasons are used by the notifications so they can't include any of this stuff either.

      Attachments

        Activity

          People

            mwent Marek Went (Inactive)
            bmccoy bmccoy
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: