Skip to content

catalog diff should set non-zero error code when evaluates a broken catalog #45

@vchepkov

Description

@vchepkov

Even though problems with catalog are found, puppet catalog diff returns 0 as error code:

# puppet catalog diff puppet.example.com/development puppet.example.bnaint.com/fix_loop --certless --show_resource_diff
Notice: Add --debug for realtime output, add --render-as {json,yaml} for parsed output
Error: Unable to compile catalog for node1.example.com
	Error parsing json output of puppet catalog query for node1.bnaint.com: source 'Internal Server Erro' not in PSON!. Content: Internal Server Error: org.jruby.exceptions.RuntimeError: (PreformattedError) Evaluation Error: Resource type not found: Bwip::Rails_app (file: /etc/puppetlabs/code/environments/development/modules/bpub/manifests/bwip.pp, line: 39, column: 21) on node pubdevx-opns102.bnaint.com
Error: Unable to compile catalog for node2.example.com
	Error parsing json output of puppet catalog query for node2.example.com: source 'Internal Server Erro' not in PSON!. Content: Internal Server Error: org.jruby.exceptions.RuntimeError: (PreformattedError) Evaluation Error: Resource type not found: Bwip::Rails_app (file: /etc/puppetlabs/code/environments/development/modules/bpub/manifests/bwip.pp, line: 39, column: 21) on node pubdevx-opns202.bnaint.com
Notice: Add --debug for realtime output, add --render-as {json,yaml} for parsed output
Error: Missing partner catalog for node1.example.com.pson
Error: Missing partner catalog for node2.example.com.pson
....
# echo $?
0


Metadata

Metadata

Assignees

No one assigned

    Labels

    bugfixSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions