On 4/12/24 09:26, jm...@redhat.com wrote:
> From: Jakob Meng <c...@jakobmeng.de>
> 
> With the '--pretty' option, appctl.py will now print JSON output in a
> more readable fashion, i.e. with additional line breaks, spaces and
> sorted dictionary keys. The pretty-printed output from appctl.py is not
> strictly the same as with ovs-appctl because of both use different
> pretty-printing implementations.
> 
> Signed-off-by: Jakob Meng <c...@jakobmeng.de>
> ---
>  NEWS                         |  3 +++
>  python/ovs/unixctl/client.py |  4 ++--
>  tests/appctl.py              | 16 ++++++++++++++--
>  tests/unixctl-py.at          |  5 +++++
>  4 files changed, 24 insertions(+), 4 deletions(-)
> 
> diff --git a/NEWS b/NEWS
> index 52cadbe0d..957351acb 100644
> --- a/NEWS
> +++ b/NEWS
> @@ -15,6 +15,9 @@ Post-v3.3.0
>         with indentation.
>     - Python:
>       * Added support for choosing the output format, e.g. 'json' or 'text'.
> +     * Added new option [--pretty] to print JSON output in a readable 
> fashion.
> +       E.g. members of objects and elements of arrays are printed one per 
> line,
> +       with indentation.

The option was added to the test-only code.  This shouldn't be
in the news.  If we move the formatting responsibility out
of the UnixctlClient to the user, this patch may not be needed
at all.

Best regards, Ilya Maximets.
_______________________________________________
dev mailing list
d...@openvswitch.org
https://mail.openvswitch.org/mailman/listinfo/ovs-dev

Reply via email to