Issue #21236 has been updated by Charlie Sharpsteen.

Tracker changed from Bug to Feature
Status changed from Investigating to Needs Decision
Assignee changed from Charlie Sharpsteen to eric sorenson
Keywords changed from customer to noop customer

I'm changing this to a feature request because `--detailed-exit-codes` is only 
documented to return a 2 when something actually changes and `noop` implies 
that no changes are made.

One difficulty I see with this request is that in no-op mode, Puppet can only 
determine that it would attempt to synchronize a resource. In most cases it is 
impossible to determine if that resource would have actually changed or errored 
out unless the sync is actually attempted. This implies that Puppet has to be 
run in enforcement mode to resolve ambiguity between "changed" and "failed" and 
therefore return a 2, 4 or 6.

Eric, any thoughts about this request?

----------------------------------------
Feature #21236: --detailed-exit-codes not honored when --noop is used
https://projects.puppetlabs.com/issues/21236#change-93058

* Author: Lee Lowder
* Status: Needs Decision
* Priority: Normal
* Assignee: eric sorenson
* Category: error reporting
* Target version: 
* Affected Puppet version: 
* Keywords: noop customer
* Branch: 
----------------------------------------
According to the man page,

>--detailed-exitcodes
>   Provide transaction information via exit codes. If this is enabled, an exit 
> code of '2' means there were changes, an exit code of '4' means there were 
> failures during the transaction, and an exit code of '6' means there were >   
> both changes and failures.

If --noop is used, puppet always returns with an exit code of 0.

While technically correct, as nothing changed, it is not the expected result 
nor is it terribly useful.

Puppet should return 0 if nothing would have changed, 2 if something would have 
changed, 4 if errors and 6 if potential changes and errors when ran with --noop.



-- 
You have received this notification because you have either subscribed to it, 
or are involved in it.
To change your notification preferences, please click here: 
http://projects.puppetlabs.com/my/account

-- 
You received this message because you are subscribed to the Google Groups 
"Puppet Bugs" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/puppet-bugs.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to