Comment 2 for bug 1587445

Gustavo Niemeyer (niemeyer) wrote :

What we fixed earlier was that it was an error message, and we transformed it into the usual output because an empty list is in general not an error.

It's okay to display a message instead of the header as well, but in that case it's not okay for that message to be on stdout, though. To be tool-friendly, the message must be on stderr, and the return code should remain be 0 because no snaps is not an erroneous case for a "list all" operation. The output on stdout can remain empty too.

As it is today, "if [ snap list | grep hello-world ]" will find something.

Can we please fix that?