puppetlabs/puppet — pull request #1276 by joshcooper (2012-11-14 01:17:21+00:00)
Title: (#17007) Restore execute semantics

See ticket 17007 for the gory details, but basically calling `Puppet::Util::Executor.execute(command)` will raise an exception if the command returns a non-zero exit code, but calling `execute(command, :combine => false)` won't. Surprised? Yeah, I was too.

These commits restore the execution semantics that existed in 2.7.x.

Ideally, I'd like to implement the correct semantics in `Puppet::Util::Execution.execute`, and preserve the old semantics in `Puppet::Util.execute`, for providers, functions, etc that may be using the old method directly. But since providers can just call `execute` (its an instance and class method on the provider), it seems we need a different method name, e.g. `execute2`. But since 3.0 is already out, we can't just rename `Puppet::Util::Execute.execute`.

Comments welcome.