On Monday, September 19, 2016 at 10:03:14 AM UTC-5, R.I. Pienaar wrote:
>
>
>
> On 19 Sep 2016, at 15:31, jcbollinger <john.bo...@stjude.org <javascript:>> 
> wrote:
> I see a difference between 3.8 and 4.6 with respect to the result of 
> interpolating an array into a string.  In Puppet 3 (and earlier) you get a 
> concatenation of the stringifications of all the elements, whereas in 
> Puppet 4, you get a more formatted representation.  I would have expected 
> such a change to be applied during a major version update -- so between 3.x 
> and 4.0 -- but a quick browse of the release notes does not appear to 
> mention it.
>
> This is not a puppet behaviour change. Newer Ruby does nicer looking to_s 
> on arrays that's why
>
>

I'm prepared to believe that there's no Puppet code change, which would 
explain why it's not documented in any release notes, but there's certainly 
an observable behavior difference between the two example runs.  If that is 
not to be accounted a Puppet behavior change then I suppose it must also be 
observable with (only) Puppet 3.8 running on different Ruby versions.  
That's a nice gotcha if you happen to rely on interpolating arrays (not 
that I would recommend doing so in any case).

On the other hand, I observe that the current (4.6) Puppet docs document 
the array interpolation format 
<https://docs.puppet.com/puppet/4.6/reference/lang_data_string.html#conversion-of-interpolated-values>,
 
independent of underlying Ruby.  That may now be a distinction without much 
practical difference, but it's the right thing to do: details of the 
infrastructure -- and especially changes to them -- ought not to leak out 
into Puppet's user-facing behavior.  This sort of thing will become more 
important as Puppet continues its movement away from Ruby as the main 
implementation language.

In any case, inasmuch as the OP was asking about behavioral differences, it 
is highly relevant that the one observable difference of any significance 
arises not because of a difference in the version of Puppet, but because of 
a difference in the version of the Ruby underneath.


John

-- 
You received this message because you are subscribed to the Google Groups 
"Puppet Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to puppet-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/puppet-users/ed271976-8776-4dc1-bb71-166fd5db8e82%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to