-
Notifications
You must be signed in to change notification settings - Fork 267
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
Remove condition which create wrong scheduling on JeOS #13668
Conversation
@@ -84,23 +88,44 @@ sub load_host_tests_docker { | |||
loadtest "containers/container_diff" if (is_opensuse()); | |||
} | |||
|
|||
sub load_jeos_containers { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is wrong. We already have a function loader for podman and docker tests. You are duplicating a lot of code here which is unnecessary.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As an urgent task i tried to keep the scheduling clean and isolated. in other case i would have many moving parts. Like many "if else". ofc i would like to avoid and improve this part, which appears twice
if (is_opensuse_jeos()) {
load_jeos_containers();
} else
but it was the faster approach i came up initially. but it could happen later.
I also think that the load_jeos_containers is a good idea for now to not interfere, as jeos is kinda special case, and doing this so, we decouple the scheduling from sle.
@@ -258,7 +258,7 @@ sub load_default_tests { | |||
} | |||
|
|||
# load the tests in the right order | |||
if (is_jeos && !is_container_test) { | |||
if (is_jeos) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This would break the containers_*
tests that are actually not JeOS but have flavor JeOS-for-kvm-and-xen
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
my proposal is actually only having this change :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@mloviska if this is one of the test cases that you had in mind, I run a VR. i cant see how the implementation affects it.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
i did an effort to fix this with a dirty approach. I dont know. maybe @jlausuch suggestion can clean this mess.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this change is ready for review Still i can remove the duplication of the new block but feel free to go on(because the urgency) if you want and we will fix in another PR if it is needed.
This is my proposal I had in mind before you came up with this PR. Sorry if I didn't present it before, I hope it's fine. |
91634b0
to
0f55413
Compare
I would really like to fix the issue from the root, which is the openqa job setup, not having a hacky code to handle any weird setups (e.g. booting centos with JeOS flavor). |
i will unassign myself from this ticket then. i have no idea what is the right way. But i know that this would be a much bigger change, so it is up to you. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For a fix this is too complex and we are applying a fix plus some additional cleanup at the same time. If it is an urgent fix, then please only fix the issue and do the cleanup afterwards.
In particular: Why don't we apply Joses fix #13672 so that the issue is resolved and then continue with this PR to make it nice without time pressure?
@@ -554,6 +554,7 @@ sub load_system_role_tests { | |||
} | |||
} | |||
sub load_jeos_tests { | |||
return if (get_var('CONTAINER_RUNTIME', 0) && (is_leap && is_ppc64le) || check_var('CONTAINERS_NO_SUSE_OS', 1)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please add a comment, why this is necessary
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yianni, please add # a comment
😄
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
added
} | ||
|
||
sub is_container_jeos { | ||
return (get_var('CONTAINER_RUNTIME', 0) && ((is_leap && is_ppc64le) || check_var('CONTAINERS_NO_SUSE_OS', 1))); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't understand the purpose of this check. Please add a comment explaining what we get in doing those checks.
|
||
sub load_container_tests { | ||
my $runtime = get_required_var('CONTAINER_RUNTIME'); | ||
if (get_var('BOOT_HDD_IMAGE')) { | ||
loadtest 'installation/bootloader_zkvm' if is_s390x; | ||
loadtest 'boot/boot_to_desktop'; | ||
loadtest 'boot/boot_to_desktop' if (is_container_jeos || !is_jeos); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
By default we always run boot/boot_to_desktop
, so this logic is flawed to fail in the future.
The default should always be performed unless
the exception and not the other way around. So instead of asking "right now, boot_to_desktop needs to be executed if ...." one should approach it as "boot_to_desktop should always be executed, except for the special case, that ....
TL'DR: Please change it to something like
loadtest 'boot/boot_to_desktop' if (is_container_jeos || !is_jeos); | |
loadtest 'boot/boot_to_desktop' unless ... ; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
but remains the default. i tried with unless but there were tests failing. i would like to leave it as it is, because this is getting complex enough and i think it is going to be a better approach soon after.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It does not remain the default, because it is only executed if a certain condition is fulfilled.
The opposite is that it is executed by default, unless a condition is fulfilled.
The difference is opt-in by default or opt-out by default.
Why is this important? Because if we add another test e.g. for SLE Micro, that one would not execute boot/boot_to_desktop
unless we add that flavor to the if
condition.
If we have a exclusion logic (unless
) then every new test runs, however weird they might be, will schedule boot_to_desktop
by default.
The main issue was the condition is `products/opensuse/main.pm` in L261 which was evaluated to *false* and then later another condition linked to *load_container_tests*. The solution was to remove this condition, so letting *load_jeos_tests* run first and then find *load_container_tests* which in turn will *load_jeos_containers* as it was before. Signed-off-by: Ioannis Bonatakis <ybonatakis@suse.com> test containers_on Signed-off-by: Ioannis Bonatakis <ybonatakis@suse.com>
deprecated from #13746 |
The main issue was the condition is
products/opensuse/main.pm
in L261which was evaluated to false and then later another condition linked to load_container_tests.
The solution was to remove this condition, so letting load_jeos_tests run first and then
find load_container_tests which in turn will load_jeos_containers as it was before.
Signed-off-by: Ioannis Bonatakis ybonatakis@suse.com
https://openqa.opensuse.org/tests/2029918
https://openqa.opensuse.org/tests/2029917
https://openqa.opensuse.org/tests/2030191
https://openqa.suse.de/tests/7650121
https://openqa.suse.de/tests/7650120
VR for 366eb59:
❯ openqa-clone-custom-git-refspec #13668 https://openqa.opensuse.org/tests/2031116
Github oauth token provided, performing authenticated requests
Created job #2036430: opensuse-15.3-JeOS-for-kvm-and-xen-ppc64le-Build9.279-containers_docker_on_15.2_gm@ppc64le -> https://openqa.opensuse.org/t2036430
❯ openqa-clone-custom-git-refspec #13668 https://openqa.opensuse.org/tests/2031115
Github oauth token provided, performing authenticated requests
Created job #2036431: opensuse-15.3-JeOS-for-kvm-and-xen-ppc64le-Build9.279-containers_podman_on_15.2_gm@ppc64le -> https://openqa.opensuse.org/t2036431
❯ openqa-clone-custom-git-refspec #13668 https://openqa.opensuse.org/tests/2034865
Github oauth token provided, performing authenticated requests
Created job #2036432: opensuse-Tumbleweed-JeOS-for-kvm-and-xen-x86_64-Build20211113-jeos-containers@64bit_virtio -> https://openqa.opensuse.org/t2036432
❯ openqa-clone-custom-git-refspec #13668 https://openqa.opensuse.org/tests/2034867
Github oauth token provided, performing authenticated requests
Created job #2036433: opensuse-Tumbleweed-JeOS-for-kvm-and-xen-x86_64-Build20211113-jeos@64bit_virtio -> https://openqa.opensuse.org/t2036433
❯
❯ openqa-clone-custom-git-refspec #13668 https://openqa.opensuse.org/tests/2031132
Github oauth token provided, performing authenticated requests
Created job #2036434: opensuse-15.3-JeOS-for-AArch64-aarch64-Build9.279-jeos-containers@USBboot_aarch64 -> https://openqa.opensuse.org/t2036434
❯ openqa-clone-custom-git-refspec #13668 https://openqa.opensuse.org/tests/2031116
Github oauth token provided, performing authenticated requests
Created job #2036436: opensuse-15.3-JeOS-for-kvm-and-xen-ppc64le-Build9.279-containers_docker_on_15.2_gm@ppc64le -> https://openqa.opensuse.org/t2036436
❯ openqa-clone-custom-git-refspec #13668 https://openqa.opensuse.org/tests/2031118
Github oauth token provided, performing authenticated requests
Created job #2036437: opensuse-15.3-JeOS-for-kvm-and-xen-x86_64-Build9.279-containers_on_centos_host_x86_64@64bit-2G -> https://openqa.opensuse.org/t2036437
❯
❯ openqa-clone-custom-git-refspec #13668 https://openqa.suse.de/tests/7675887
Github oauth token provided, performing authenticated requests
Created job #7678825: sle-15-SP3-JeOS-for-kvm-and-xen-Updates-x86_64-Build20211115-1-jeos-filesystem@uefi-virtio-vga -> https://openqa.suse.de/t7678825
❯ openqa-clone-custom-git-refspec #13668 https://openqa.suse.de/tests/7677181
Github oauth token provided, performing authenticated requests
Created job #7678827: sle-15-SP3-Server-DVD-Updates-x86_64-Build20211115-1-docker_tests@64bit -> https://openqa.suse.de/t7678827