Hi Frank, On irc we discussed some issues with trying to disable debuginfod client for valgrind while actually using it in the to be tested executable. The main issue is that valgrind and the test executable are actually one and the same. So disabling or enabling DEBUGINFOD_URLS for one also disables or enables it for the other.
So maybe it is just simpler to disable testing under valgrind for those tests that are testing the debuginfod client cache dir directly. That is what the attached patch does. It is pity to not have valgrind run over all the tests, but it is the simplest I could come up with. And this has given us more headaches than we deserve in the first place. What do you think? Thanks, Mark
From ad3c57cfb68d1ef5f6a1d426578d8005048c251e Mon Sep 17 00:00:00 2001 From: Mark Wielaard <m...@klomp.org> Date: Fri, 2 Jul 2021 18:16:00 +0200 Subject: [PATCH] run-debuginfod-find.sh: Disable valgrind for debuginfod client cache tests valgrind itself might use the debuginfod client. So disable valgrind when testing the cache. Signed-off-by: Mark Wielaard <m...@klomp.org> --- tests/ChangeLog | 5 +++++ tests/run-debuginfod-find.sh | 5 +++++ 2 files changed, 10 insertions(+) diff --git a/tests/ChangeLog b/tests/ChangeLog index d8fa97fa..a0e4ec52 100644 --- a/tests/ChangeLog +++ b/tests/ChangeLog @@ -1,3 +1,8 @@ +2021-07-02 Mark Wielaard <m...@klomp.org> + + * run-debuginfo-find.sh: unset VALGRIND_CMD before testing debuginfod + client cache. + 2021-06-16 Frank Ch. Eigler <f...@redhat.com> * run-debuginfod-find.sh: Fix intermittent groom/stale failure, diff --git a/tests/run-debuginfod-find.sh b/tests/run-debuginfod-find.sh index 456dc2f8..74a5ceff 100755 --- a/tests/run-debuginfod-find.sh +++ b/tests/run-debuginfod-find.sh @@ -583,6 +583,11 @@ curl -s http://127.0.0.1:$PORT2/buildid/deadbeef/debuginfo > /dev/null || true curl -s http://127.0.0.1:$PORT2/buildid/deadbeef/badtype > /dev/null || true (curl -s http://127.0.0.1:$PORT2/metrics | grep 'badtype') && false +# DISABLE VALGRIND checking because valgrind might use debuginfod client +# requests itself, causing confusion about who put what in the cache. +# It stays disabled till the end of this test. +unset VALGRIND_CMD + # Confirm that reused curl connections survive 404 errors. # The rm's force an uncached fetch rm -f $DEBUGINFOD_CACHE_PATH/$BUILDID/debuginfo .client_cache*/$BUILDID/debuginfo -- 2.18.4