-
Notifications
You must be signed in to change notification settings - Fork 84
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-1427] Fix rpm -Va parsing and improve speed #1319
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #1319 +/- ##
=======================================
Coverage 96.18% 96.18%
=======================================
Files 58 58
Lines 4826 4828 +2
Branches 847 848 +1
=======================================
+ Hits 4642 4644 +2
Misses 106 106
Partials 78 78
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
1188693
to
462e786
Compare
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.
LGTM! But just to lean more on comments and commit messages.
In the commit it says
Fix rpm -Va parsing when backing up package files to accept also ghost
files. Those files aren't backed up, but message about invalid output
was removed by this.
I'd change this around to something along the lines of "Fix invalid output in rpm -Va
due to ghost files being incorrectly parsed. Ghost files are not needed by the tool as they relate to x and can be safely skipped" or something in that regard. At least to put the reason for the fix in the beginning and not at the end of the paragraph
Improve speed of rpm -Va command by using --nodeps switch. This improves
speed of the command by 40 % and doesn't generate unimportant info about
unsatisfied dependencies for packages.
If you have a statistic of 40% can you add that to the message. 40% is also very inconvenient by itself. For example, if something took 1.0s and was improved to now only take 0.1s overall, that is a 90% performance increase, but overall you would never notice
@@ -390,7 +390,7 @@ def generate_rpm_va(self, log_filename=PRE_RPM_VA_LOG_FILENAME): | |||
" minutes. It can be disabled by using the" | |||
" --no-rpm-va option." | |||
) | |||
rpm_va, _ = utils.run_subprocess(["rpm", "-Va"], print_output=False) | |||
rpm_va, _ = utils.run_subprocess(["rpm", "-Va", "--nodeps"], print_output=False) |
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.
What does --nodeps
do? Add a comment here
# Skip ghost files RHELC-1427 | ||
if file["file_type"] == "g": | ||
continue |
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.
Why are we skipping? Comment explaining why. Imagine the person reading doesn't know what ghost files are used for or why we don't care about it
462e786
to
622ea9d
Compare
@Venefilyn I've improved the comments and commit description. Do you like those changes? |
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.
LGTM! Just a small nitpick on the commit message but not a blocker, can be merged
Improve speed of rpm -Va command by using --nodeps switch. This improves
speed of the command and doesn't generate unimportant info about
unsatisfied dependencies for packages.
Improves speed is mentioned twice here
/packit test --labels sanity |
/packit test --labels sanity |
Tests failing due to this:
|
622ea9d
to
620a03d
Compare
620a03d
to
3e437cb
Compare
/packit test --labels sanity |
Fix rpm -Va parsing to accept also ghosts files. Do not generate message about invalid output of lines related to ghosts files anymore. Those files aren't backed up as they are temporary. Extend rpm -Va command by --nodeps switch. This improves speed of the command and doesn't generate unimportant info about unsatisfied dependencies for packages.
3e437cb
to
265ccc5
Compare
Fix rpm -Va parsing to accept also ghosts files. Do not generate message
about invalid output of lines related to ghosts files anymore. Those files
aren't backed up as they are temporary.
Extend rpm -Va command by --nodeps switch. This improves
speed of the command and doesn't generate unimportant info about
unsatisfied dependencies for packages.
Jira Issues:
Checklist
[RHELC-]
or[HMS-]
is part of the PR titleRelease Pending
if relevant