-
Notifications
You must be signed in to change notification settings - Fork 81
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
[RHELC-1540] Fix bug with duplicate packages check when running with Satellite offline #1219
[RHELC-1540] Fix bug with duplicate packages check when running with Satellite offline #1219
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #1219 +/- ##
==========================================
- Coverage 95.44% 95.42% -0.03%
==========================================
Files 54 54
Lines 4723 4700 -23
Branches 834 831 -3
==========================================
- Hits 4508 4485 -23
- Misses 132 133 +1
+ Partials 83 82 -1
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
convert2rhel/unit_tests/actions/system_checks/duplicate_packages_test.py
Outdated
Show resolved
Hide resolved
0e0df6f
to
6cb4bae
Compare
/packit test --labels tier0 |
49947de
to
3ed3f49
Compare
3ed3f49
to
5b154c6
Compare
convert2rhel/unit_tests/actions/system_checks/duplicate_packages_test.py
Outdated
Show resolved
Hide resolved
convert2rhel/unit_tests/actions/system_checks/duplicate_packages_test.py
Show resolved
Hide resolved
convert2rhel/unit_tests/actions/system_checks/duplicate_packages_test.py
Show resolved
Hide resolved
convert2rhel/unit_tests/actions/system_checks/duplicate_packages_test.py
Show resolved
Hide resolved
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.
Looks good
Co-authored-by: Adam Hosek <hosek.adam@outlook.com>
3d1db1a
to
4a49abb
Compare
This PR adds handlers for errors raised when running the DUPLICATE_PACKAGES check with Satellite on an offline system. On EL7 systems for this particular error case the return code is 0 and the output is [Errno -2] Name or service not known. while on EL8 the return code is 1 and the output is Failed to download metadata for repo [example repo]: Cannot download repomd.xml: Cannot download repodata/repomd.xml: All mirrors were tried.
For EL7 we check for that specific output and for EL8 we check the return code. Both cases raise a WARNING DUPLICATE_PACKAGE_CHECK_FAILED and inform the user we couldn't perform the check and recommend they ensure they can access all repos enabled on their system and re-run convert2rhel or check for duplicate packages themselves. This way we don't hinder the conversion for offline systems on satellite while informing them how to remediate the failure.
Jira Issues:
Checklist
[RHELC-]
is part of the PR titleRelease Pending
if relevant