[Pkg-puppet-devel] [SCM] Puppet packaging for Debian branch, upstream, updated. puppet-0.24.5-rc3-1601-gf8c1b08
James Turnbull
james at lovedthanlost.net
Fri Jan 15 09:07:05 UTC 2010
The following commit has been merged in the upstream branch:
commit 3fdc8effbe25c9653d8bc86f2d4847984d4cb6f3
Author: Markus Roberts <Markus at reality.com>
Date: Mon Nov 9 15:10:46 2009 -0800
Ticket #2770 (deserializing Exec[...]s with "\n"s)
The resource reference logic wasn't handling resources with "\n"s
in their namevars gracefully, and detection of this was complicated
by infelicitous exception reporting.
Note that this patch will require a merge when combined with the
patch for #2657.
Signed-off-by: Markus Roberts <Markus at reality.com>
diff --git a/lib/puppet/external/pson/pure.rb b/lib/puppet/external/pson/pure.rb
index 43f39b2..7bb18aa 100644
--- a/lib/puppet/external/pson/pure.rb
+++ b/lib/puppet/external/pson/pure.rb
@@ -11,8 +11,8 @@ module PSON
UTF8toUTF16 = Iconv.new('utf-16be', 'utf-8') # :nodoc:
UTF8toUTF16.iconv('no bom')
rescue LoadError
- raise MissingUnicodeSupport,
- "iconv couldn't be loaded, which is required for UTF-8/UTF-16 conversions"
+ # We actually don't care
+ Puppet.warning "iconv couldn't be loaded, which is required for UTF-8/UTF-16 conversions"
rescue Errno::EINVAL, Iconv::InvalidEncoding
# Iconv doesn't support big endian utf-16. Let's try to hack this manually
# into the converters.
diff --git a/lib/puppet/resource/catalog.rb b/lib/puppet/resource/catalog.rb
index 5bf9a83..09c0994 100644
--- a/lib/puppet/resource/catalog.rb
+++ b/lib/puppet/resource/catalog.rb
@@ -430,12 +430,12 @@ class Puppet::Resource::Catalog < Puppet::SimpleGraph
# the class.
edge = Puppet::Relationship.from_pson(edge) if edge.is_a?(Hash)
unless source = result.resource(edge.source)
- raise ArgumentError, "Could not convert from pson: Could not find relationship source '%s'" % source
+ raise ArgumentError, "Could not convert from pson: Could not find relationship source #{edge.source.inspect}"
end
edge.source = source
unless target = result.resource(edge.target)
- raise ArgumentError, "Could not convert from pson: Could not find relationship target '%s'" % target
+ raise ArgumentError, "Could not convert from pson: Could not find relationship target #{edge.target.inspect}"
end
edge.target = target
diff --git a/lib/puppet/resource/reference.rb b/lib/puppet/resource/reference.rb
index c205f10..37522ff 100644
--- a/lib/puppet/resource/reference.rb
+++ b/lib/puppet/resource/reference.rb
@@ -50,7 +50,7 @@ class Puppet::Resource::Reference
# If the title has square brackets, treat it like a reference and
# set things appropriately; else, just set it.
def title=(value)
- if value =~ /^([^\[\]]+)\[(.+)\]$/
+ if value =~ /^([^\[\]]+)\[(.+)\]$/m
self.type = $1
@title = $2
else
--
Puppet packaging for Debian
More information about the Pkg-puppet-devel
mailing list