Uploaded image for project: 'Puppet'
  1. Puppet
  2. PUP-4845

epp trims leading whitespace when it should not.

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Normal
    • Resolution: Duplicate
    • Affects Version/s: PUP 3.8.0, PUP 3.8.1
    • Fix Version/s: None
    • Component/s: Language
    • Labels:
      None
    • Template:

      Description

      Using the following epp template:

                    Welcome to <%= $fqdn %>
       
      Operating System: <%= $operatingsystem %> <%= $operatingsystemrelease %>
                Kernel: <%= $kernelrelease %>
        Puppet Version: <%= $puppetversion %>
            Processors:
      <% $processors['models'].each | $model | { -%>
                        <%= $model %>
      <% } -%>
       
      This computer is managed by Puppet and manual changes may be reverted
      at any time. All connections are monitored and recorded.
       
          Disconnect IMMEDIATELY if you are not an authorized user!
       
         Why is all this whitespace removed?
                blah blah
      

      this is the resulting file:

                    Welcome to master.puppetlabs.vm
       
      Operating System: CentOS 6.6
                Kernel: 2.6.32-504.el6.x86_64
        Puppet Version: 3.8.0 (Puppet Enterprise 3.8.0)
            Processors:
      Intel(R) Core(TM) i5-4308U CPU @ 2.80GHz
      Intel(R) Core(TM) i5-4308U CPU @ 2.80GHz
      This computer is managed by Puppet and manual changes may be reverted
      at any time. All connections are monitored and recorded.
      Disconnect IMMEDIATELY if you are not an authorized user!
      Why is all this whitespace removed?
      blah blah
      

      Note that as soon as I include a trailing whitespace chomper, all subsequent lines have their leading whitespace eaten. If I stick in <%# comments #%> I can get it to stop, but that leaves extra blank lines in the output.

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              Unassigned
              Reporter:
              ben.ford Ben Ford
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:

                  Zendesk Support