Re: [Puppet-dev] [PATCH/puppet 1/1] (#7788) Allow gem directories to be searched while autoloading

2011-06-04 Thread markus
> > > > > > + if Puppet.features.rubygems? > > > > +Thread.current[:gemsearch_directories] ||= [] > > > > +Thread.current[:gemsearch_directories] = > > > > Gem.all_load_paths > > > > if Thread.current[:gemsearch_directories].empty? > > > > +return Thread.current[:gemse

Re: [Puppet-dev] [PATCH/puppet 1/1] (#7788) Allow gem directories to be searched while autoloading

2011-06-04 Thread R.I.Pienaar
- Original Message - > R.I. -- > > > > + if Puppet.features.rubygems? > > > +Thread.current[:gemsearch_directories] ||= [] > > > +Thread.current[:gemsearch_directories] = > > > Gem.all_load_paths > > > if Thread.current[:gemsearch_directories].empty? > > > +r

Re: [Puppet-dev] [PATCH/puppet 1/1] (#7788) Allow gem directories to be searched while autoloading

2011-06-04 Thread markus
R.I. -- > > + if Puppet.features.rubygems? > > +Thread.current[:gemsearch_directories] ||= [] > > +Thread.current[:gemsearch_directories] = Gem.all_load_paths > > if Thread.current[:gemsearch_directories].empty? > > +return Thread.current[:gemsearch_directories] > > +

Re: [Puppet-dev] [PATCH/puppet 1/1] (#7788) Allow gem directories to be searched while autoloading

2011-06-04 Thread R.I.Pienaar
- Original Message - > + if Puppet.features.rubygems? > +Thread.current[:gemsearch_directories] ||= [] > +Thread.current[:gemsearch_directories] = Gem.all_load_paths > if Thread.current[:gemsearch_directories].empty? > +return Thread.current[:gemsearch_direct

Re: [Puppet-dev] [PATCH/puppet 1/1] (#7788) Allow gem directories to be searched while autoloading

2011-06-04 Thread James Turnbull
R.I.Pienaar wrote: > This allows rubygems to be used to extend or override puppet behavior. > > Unfortunately the features system uses the autoloader so checking for > the rubygems feature causes a call loop. It's possible that a more > elegant way to avoid this exist rather than just checking th

[Puppet-dev] [PATCH/puppet 1/1] (#7788) Allow gem directories to be searched while autoloading

2011-06-04 Thread R.I.Pienaar
This allows rubygems to be used to extend or override puppet behavior. Unfortunately the features system uses the autoloader so checking for the rubygems feature causes a call loop. It's possible that a more elegant way to avoid this exist rather than just checking the @path but this did what I n

[Puppet-dev] [PATCH/facter 2/2] (#7753) Fixed a regression introduced by fixing 7753

2011-06-04 Thread Adrien Thebo
For some reason, the :timeout option in ipaddress.rb option started causing facter to crash, since there is no timeout= method in the collection, fact, or resolution classes. Removed the option, and replaced it with a call to the limit method inside the resolution block. Signed-off-by: Adrien Theb

[Puppet-dev] [PATCH/facter 1/2] (#7753) Added error checking when adding resolves

2011-06-04 Thread Adrien Thebo
Added exception handling to the fact class. When adding a resolution to a fact, if an exception was thrown outside of the setcode block, facter would crash. Added handling so that if an exception is thrown, facter logs the error and discards the fact. Signed-off-by: Adrien Thebo --- Local-branch:

[Puppet-dev] ticket 7753 against master

2011-06-04 Thread Adrien Thebo
This adds error handling when actually adding a new resolve to a fact. It also fixes a regression in the ipaddress fact and uses the correct method of setting a timeout in fact resolution. -- You received this message because you are subscribed to the Google Groups "Puppet Developers" group. To