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

Change STO/SGO bundles sanity check #595

Merged
merged 3 commits into from
May 10, 2024

Conversation

vkmc
Copy link
Collaborator

@vkmc vkmc commented May 8, 2024

stdout for "oc image info" should be checked instead of the rc to make sure that the correct bundle is being used

stdout for "oc image info" should be checked
instead of the rc to make sure that the correct
bundle is being used
@vkmc vkmc added the do-not-merge Code is not ready to be merged label May 8, 2024
- name: Fail is the expected STO bundle was not correctly fetched
ansible.builtin.fail:
msg: "The requested STO bundle couldn't be retrieved from the bundle registry. Check configuration for the bundles registry and retry."
when: "__service_telemetry_bundle_image_path not in sto_bundle_info.stdout"
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Regarding verbosity, this check is the same as the assert below.

You could update the message for assert to list the failed bundle.
Something like:

fail_msg:
    "The requested bundle(s) ({% if __service_telemetry_bundle_image_path not in sto_bundle_info.stdout %}STO{%endif%}, {% if __smart_gateway_bundle_image_path not in sto_bundle_info.stdout %}SGO{%endif%}) couldn't be retrieved..."

i.e. use jinja2 templating to add in the name of the bundles(s) that weren't retrievable to the task in L98.
I'm assuming that you wanted to add these tests here so that there is a useful message to tell you which bundle was missing.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the review Emma. I opted for dropping the assertion altogether and just stick with the fail checks. Also, kept the debug, I think it's useful info.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That's fair. looks good

Make checks simpler and more granular by using the
fail module instead of the assertion for each of
the bundles.
@vkmc vkmc removed the do-not-merge Code is not ready to be merged label May 9, 2024
- name: Fail is the expected STO bundle was not correctly fetched
ansible.builtin.fail:
msg: "The requested STO bundle couldn't be retrieved from the bundle registry. Check configuration for the bundles registry and retry."
when: "__service_telemetry_bundle_image_path not in sto_bundle_info.stdout"
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That's fair. looks good

build/stf-run-ci/tasks/setup_registry_auth.yml Outdated Show resolved Hide resolved
@vkmc vkmc enabled auto-merge (squash) May 10, 2024 08:04
Copy link

Build failed (check pipeline). Post recheck (without leading slash)
to rerun all jobs. Make sure the failure cause has been resolved before
you rerun jobs.

https://review.rdoproject.org/zuul/buildset/91d91f7953684c4fbd72a3b427464219

✔️ stf-crc-ocp_412-local_build SUCCESS in 36m 30s
✔️ stf-crc-ocp_414-local_build SUCCESS in 39m 17s
stf-crc-ocp_412-local_build-index_deploy RETRY_LIMIT in 19m 23s
✔️ stf-crc-ocp_414-local_build-index_deploy SUCCESS in 48m 53s

@vkmc
Copy link
Collaborator Author

vkmc commented May 10, 2024

recheck

Copy link

Build failed (check pipeline). Post recheck (without leading slash)
to rerun all jobs. Make sure the failure cause has been resolved before
you rerun jobs.

https://review.rdoproject.org/zuul/buildset/0bca4b8e27334cae80e388dfa59ecd25

✔️ stf-crc-ocp_412-local_build SUCCESS in 36m 16s
✔️ stf-crc-ocp_414-local_build SUCCESS in 39m 58s
stf-crc-ocp_412-local_build-index_deploy FAILURE in 20m 14s
✔️ stf-crc-ocp_414-local_build-index_deploy SUCCESS in 36m 38s

@vkmc vkmc disabled auto-merge May 10, 2024 11:07
@vkmc
Copy link
Collaborator Author

vkmc commented May 10, 2024

recheck

Copy link

Build failed (check pipeline). Post recheck (without leading slash)
to rerun all jobs. Make sure the failure cause has been resolved before
you rerun jobs.

https://review.rdoproject.org/zuul/buildset/a77a4dcb9f614e01a9ec595b6f042109

✔️ stf-crc-ocp_412-local_build SUCCESS in 35m 26s
✔️ stf-crc-ocp_414-local_build SUCCESS in 40m 50s
stf-crc-ocp_412-local_build-index_deploy RETRY_LIMIT in 19m 13s
✔️ stf-crc-ocp_414-local_build-index_deploy SUCCESS in 44m 29s

@vkmc vkmc merged commit acdb05f into master May 10, 2024
9 of 10 checks passed
@vkmc vkmc deleted the vkmc-STF-1757-bundles-registry-validations-fails branch May 10, 2024 13:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

3 participants