From eadf23a516b84be03b415db8bd174834fb70dcd2 Mon Sep 17 00:00:00 2001 From: Adam Williamson Date: Thu, 2 Mar 2023 10:16:52 -0800 Subject: [PATCH] Add an ugly workaround for FEDORA-2023-f6afa6f9e5 rebase issue There's a weird issue with the rpmostree_rebase test for this update: https://bodhi.fedoraproject.org/updates/FEDORA-2023-f6afa6f9e5#comment-2919613 it doesn't reproduce locally (I can type fine after doing the same things the test does up to the rollback) and I can't think of any possible cause, and I don't want to hold the update up. So we're just gonna work around it and hope this doesn't start happening to all F38 update tests after this goes stable. If it does, we'll have to do the workaround for all of them. The workaround is just to rollback and reboot 'blindly', instead of checking the rollback command works. The drawback is that if the rollback command fails we'll wait 7.5 minutes before giving up on it, and it'll be a bit less clear exactly what happened. Signed-off-by: Adam Williamson --- tests/rpmostree_rebase.pm | 17 +++++++++++++---- 1 file changed, 13 insertions(+), 4 deletions(-) diff --git a/tests/rpmostree_rebase.pm b/tests/rpmostree_rebase.pm index 7138ebab..b77ed99c 100644 --- a/tests/rpmostree_rebase.pm +++ b/tests/rpmostree_rebase.pm @@ -50,10 +50,19 @@ sub run { validate_script_output "rpm-ostree status -b", sub { m/$target/ }, 300; # rollback and reboot - validate_script_output "rpm-ostree rollback", sub { m/systemctl reboot/ }, 300; - script_run "systemctl reboot", 0; - - boot_to_login_screen; + if (get_var("ADVISORY") eq "FEDORA-2023-f6afa6f9e5") { + # FIXME: workaround for a very odd phenomenon with this update + # https://bodhi.fedoraproject.org/updates/FEDORA-2023-f6afa6f9e5#comment-2919613 + # if that keeps happening after the update is stable we will + # have to do this for all affected releases + script_run "rpm-ostree rollback && systemctl reboot", 0; + boot_to_login_screen(timeout => 450); + } + else { + validate_script_output "rpm-ostree rollback", sub { m/systemctl reboot/ }, 300; + script_run "systemctl reboot", 0; + boot_to_login_screen; + } $self->root_console(tty => 3); # check to make sure rollback successful