It looks like Matt and I just missed this one case in the earlier patch. There are actually surprisingly few calls to methods named "resources" in the codebase; I was expecting it to be a grep nightmare.
On Sun, Jul 11, 2010 at 10:43 PM, Luke Kanies <[email protected]> wrote: > Is the complete fix actually this simple? > > I could swear this method is used in multiple places that expect a string, > based on previous behaviour. > > My guess is that this was already fixed as part of the method rename, just > trying to make sure. > > > On Jul 11, 2010, at 10:36 PM, Jesse Wolfe wrote: > > type/user.rb was assuming that catalog.resources would return resources. >> In 0.25.x, it (confusingly) returns strings. type/user ignored this, and >> the codepath was a no-op. >> In 2.6, the method was renamed to something less confusing, causing the >> codepath in type/user to fail outright. >> This patch added a catalog.resources method that returns resource >> objects. >> As a side effect, user resources will now autorequire group resources >> again. >> >> Signed-off-by: Jesse Wolfe <[email protected]> >> --- >> lib/puppet/resource/catalog.rb | 4 ++++ >> 1 files changed, 4 insertions(+), 0 deletions(-) >> >> diff --git a/lib/puppet/resource/catalog.rb >> b/lib/puppet/resource/catalog.rb >> index e8c1429..d163fc1 100644 >> --- a/lib/puppet/resource/catalog.rb >> +++ b/lib/puppet/resource/catalog.rb >> @@ -383,6 +383,10 @@ class Puppet::Resource::Catalog < Puppet::SimpleGraph >> @resource_table.keys >> end >> >> + def resources >> + @resource_table.values.uniq >> + end >> + >> def self.from_pson(data) >> result = new(data['name']) >> >> -- >> 1.7.0.4 >> >> -- >> You received this message because you are subscribed to the Google Groups >> "Puppet Developers" group. >> To post to this group, send email to [email protected]. >> To unsubscribe from this group, send email to >> [email protected]<puppet-dev%[email protected]> >> . >> For more options, visit this group at >> http://groups.google.com/group/puppet-dev?hl=en. >> >> > > -- > Today I dialed a wrong number...The other person said, "Hello?" and > I said, "Hello, could I speak to Joey?"... > They said, "Uh...I don't think so...he's only 2 months old." > I said, "I'll wait." -- Steven Wright > --------------------------------------------------------------------- > Luke Kanies -|- http://puppetlabs.com -|- +1(615)594-8199 > > > -- > You received this message because you are subscribed to the Google Groups > "Puppet Developers" group. > To post to this group, send email to [email protected]. > To unsubscribe from this group, send email to > [email protected]<puppet-dev%[email protected]> > . > For more options, visit this group at > http://groups.google.com/group/puppet-dev?hl=en. > > -- You received this message because you are subscribed to the Google Groups "Puppet Developers" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/puppet-dev?hl=en.
