Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

test: Don't collapse dmesg in CI when there's a kernel call trace #14150

Merged
merged 1 commit into from
Sep 25, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 15 additions & 2 deletions test/main.sh
Original file line number Diff line number Diff line change
Expand Up @@ -94,9 +94,22 @@ cleanup() {

if [ "${TEST_RESULT}" != "success" ]; then
# dmesg may contain oops, IO errors, crashes, etc
echo "::group::dmesg logs"
# If there's a kernel stack trace, don't generate a collapsible group

expandDmesg=no
if journalctl --quiet --no-hostname --no-pager --boot=0 --lines=100 --dmesg --grep="Call Trace:" > /dev/null; then
expandDmesg=yes
fi

if [ "${expandDmesg}" = "no" ]; then
echo "::group::dmesg logs"
else
echo "dmesg logs"
fi
journalctl --quiet --no-hostname --no-pager --boot=0 --lines=100 --dmesg
echo "::endgroup::"
if [ "${expandDmesg}" = "no" ]; then
echo "::endgroup::"
fi
fi

if [ -n "${GITHUB_ACTIONS:-}" ]; then
Expand Down
Loading