percy / percy-agent

[Deprecated in favor of `@percy/cli`] An agent process for integrating with Percy.
https://percy.io
MIT License
22 stars 25 forks source link

CLI should exit with failure exit code if it hits an exception #606

Closed kamal closed 3 years ago

kamal commented 3 years ago

In CI, I had finalize fail because I did not set a proper nonce. However the command exited successfully.

$ percy finalize --all
[percy] StatusCodeError 409 - {"errors":[{"status":"conflict","detail":"Can only set all_shards: true for parallel builds"}]} | Wed Mar 03 2021 00:26:45 GMT+0000 (Coordinated Universal Time)

The expectation is for the CLI to exit with a non-zero exit code.

Robdel12 commented 3 years ago

This shouldn't be an issue in the new CLI: https://docs.percy.io/docs/migrating-to-percy-cli#completed (this package has been deprecated & all SDKs have been upgraded to the new toolchain)