[PATCH 0/3] iotests: enable logging prior to notrun() invocation

John Snow posted 3 patches 5 years, 6 months ago
Test docker-mingw@fedora passed
Test checkpatch passed
Test asan passed
Test docker-quick@centos7 passed
Test FreeBSD passed
Patches applied successfully (tree, apply log)
git fetch https://github.com/patchew-project/qemu tags/patchew/20200514201614.19941-1-jsnow@redhat.com
Maintainers: Max Reitz <mreitz@redhat.com>, Kevin Wolf <kwolf@redhat.com>
tests/qemu-iotests/iotests.py | 17 ++++++++++-------
1 file changed, 10 insertions(+), 7 deletions(-)
[PATCH 0/3] iotests: enable logging prior to notrun() invocation
Posted by John Snow 5 years, 6 months ago
Hi, you can take just patch 1. patches 2-3 admittedly don't do a whole
heck of a lot, because I didn't realize that ./check discards *all*
output from either stdout or stderr.

The changes are tiny, though, and maybe still worth doing in the long
run? Hm. They are archived on the list now, anyway.

--js

John Snow (3):
  iotests: log messages from notrun()
  iotests: log to stderr instead of stdout
  iotests: Categorize NOTRUN messages as INFO, not WARNING

 tests/qemu-iotests/iotests.py | 17 ++++++++++-------
 1 file changed, 10 insertions(+), 7 deletions(-)

-- 
2.21.1


Re: [PATCH 0/3] iotests: enable logging prior to notrun() invocation
Posted by Kevin Wolf 5 years, 6 months ago
Am 14.05.2020 um 22:16 hat John Snow geschrieben:
> Hi, you can take just patch 1.

Thanks, I'm doing that now.

> patches 2-3 admittedly don't do a whole heck of a lot, because I
> didn't realize that ./check discards *all* output from either stdout
> or stderr.

It doesn't discard it, but it compares it to the reference output and
prints a diff if it's non-empty.

At least for bash scripts, stderr contains important test output. Not
sure what the *_log() functions in iotests.py do, maybe they redirect
the stderr output from tools to stdout.

> The changes are tiny, though, and maybe still worth doing in the long
> run? Hm. They are archived on the list now, anyway.

We can still take these patches for a later pull request if you think we
should, though I'm not sure if they are useful given how things actually
work. I don't have a strong opinion either way (except that I don't want
to see more than a single line per test without -d, but these patches
don't try to do this even though you wrote them under the assumption
that this is how things work).

Kevin


Re: [PATCH 0/3] iotests: enable logging prior to notrun() invocation
Posted by John Snow 5 years, 5 months ago

On 5/15/20 5:57 AM, Kevin Wolf wrote:
> Am 14.05.2020 um 22:16 hat John Snow geschrieben:
>> Hi, you can take just patch 1.
> 
> Thanks, I'm doing that now.
> 
>> patches 2-3 admittedly don't do a whole heck of a lot, because I
>> didn't realize that ./check discards *all* output from either stdout
>> or stderr.
> 
> It doesn't discard it, but it compares it to the reference output and
> prints a diff if it's non-empty.
> 

notrun cases do effectively discard that output, though. I guess that's
fine if it gets logged as output otherwise.

> At least for bash scripts, stderr contains important test output. Not
> sure what the *_log() functions in iotests.py do, maybe they redirect
> the stderr output from tools to stdout.
> 
>> The changes are tiny, though, and maybe still worth doing in the long
>> run? Hm. They are archived on the list now, anyway.
> 
> We can still take these patches for a later pull request if you think we
> should, though I'm not sure if they are useful given how things actually
> work. I don't have a strong opinion either way (except that I don't want
> to see more than a single line per test without -d, but these patches
> don't try to do this even though you wrote them under the assumption
> that this is how things work).
> 

Nah, it's fine. Bigger fish to fry. Thanks!