fix(cli): fail CLI script on failed import/export (#16976)
* Test that failing export or import is done properly For each CLI entry-point we will modify, we make sure that: - a failing process exits with a non-0 exit code, - an error is logged. Signed-off-by: Étienne Boisseau-Sierra <etienne.boisseau-sierra@unipart.io> * Exit process with error if export/import failed Bubble exception up when failing import or export During a CLI import or export of dashboards, if the process fails, the exception it caught and a simple message is sent to the logger. This makes that from a shell point of view, the script was successfull — cf. #16956. To prevent this, we want to ensure that the process exits with an error (i.e., a non-0 exit-code) should the export or import fail mid-flight. Signed-off-by: Étienne Boisseau-Sierra <etienne.boisseau-sierra@unipart.io>
É
Étienne Boisseau-Sierra committed
f0c0ef70483ca8f45c9a15d8fd774cb37f7f95e3
Parent: 9ef9adf
Committed by GitHub <noreply@github.com>
on 10/29/2021, 7:56:29 AM