The Puppet Labs Issue Tracker has Moved: https://tickets.puppetlabs.com

Bug #8973

puppet apply not returning usable exit code.

Added by Max Lincoln almost 3 years ago. Updated almost 3 years ago.

Status:RejectedStart date:08/12/2011
Priority:NormalDue date:
Assignee:-% Done:

0%

Category:-
Target version:-
Affected Puppet version:2.7.1 Branch:
Keywords:

We've Moved!

Ticket tracking is now hosted in JIRA: https://tickets.puppetlabs.com

This issue is currently not available for export. If you are experiencing the issue described below, please file a new ticket in JIRA. Once a new ticket has been created, please add a link to it that points back to this Redmine ticket.


Description

Puppet apply is never returning a usable exit code. This is partly because of warnings which appear to be treated as errors.

puppet apply (without —detailed-exitcodes) This returns false positives. It returns 0 even if there is an error running the manifest. It only appears to return an error code if there is a syntax error.

puppet apply —detailed-exitcodes This is not very usable because successful runs have non-zero returns (0 or 2). It is still not usable with a wrapper because some warnings are treated as errors. This means I am getting a 4 or 6 return code even on successful runs. The warning I am seeing is:

/usr/local/lib/ruby/gems/1.9.1/gems/puppet-2.7.1/lib/puppet/provider/service/freebsd.rb:8: warning: class variable access from toplevel /usr/local/lib/ruby/gems/1.9.1/gems/puppet-2.7.1/lib/puppet/provider/service/freebsd.rb:9: warning: class variable access from toplevel /usr/local/lib/ruby/gems/1.9.1/gems/puppet-2.7.1/lib/puppet/provider/service/freebsd.rb:10: warning: class variable access from toplevel /usr/local/lib/ruby/gems/1.9.1/gems/puppet-2.7.1/lib/puppet/provider/service/bsd.rb:11: warning: class variable access from toplevel

History

#1 Updated by Max Lincoln almost 3 years ago

  • Status changed from Unreviewed to Rejected

Can no longer reproduce.

Also available in: Atom PDF