Description
The implementation of printErrorsAsPlainText simplifies the error handling in scripts by consolidating the standard and error output. This works fine if and returns a JSON error when a command fails calling an underlying Graph call.
On the other hand it will return a plain text when you are not fully specifying the parameters.
Steps to reproduce
- set base output settings for scripting
m365 cli config set --key output --value json
m365 cli config set --key errorOutput --value stdout
m365 cli config set --key showHelpOnFailure --value false
m365 cli config set --key printErrorsAsPlainText --value false
- call
m365 aad o365group get --id "076f879d-3607-4860-91da-ca6345250fbc" with an invalid id -> this will return a json
- call
m365 aad o365group get --id without additional information -> this will return a text
Expected result
The setting is considered in both cases
Environment
Description
The implementation of printErrorsAsPlainText simplifies the error handling in scripts by consolidating the standard and error output. This works fine if and returns a JSON error when a command fails calling an underlying Graph call.
On the other hand it will return a plain text when you are not fully specifying the parameters.
Steps to reproduce
m365 aad o365group get --id "076f879d-3607-4860-91da-ca6345250fbc"with an invalid id -> this will return a jsonm365 aad o365group get --idwithout additional information -> this will return a textExpected result
The setting is considered in both cases
Environment