-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
Fix descriptionSuffix for rpm Mock build steps #6316
Conversation
@@ -25,16 +25,16 @@ | |||
|
|||
|
|||
class MockStateObserver(logobserver.LogLineObserver): | |||
_line_re = re.compile(r'^.*State Changed: (.*)$') |
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 imagine this RE was correct at some point. Could you document which version of mock we now support?
I dont think this is worth to support both, but we should document 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.
Okay, I added it in the docstring. As it should still work, just not update the build step description on mock progress, perhaps it doesn't need documentation in the actual user docs?
768a0d0
to
5788897
Compare
LGTM, please prefix your commit description with |
This fixes the build step summary so that it updates nicely, for example "mock buildsrpm [dnf install]" when Mock step is running. Fix MockStateObserver that looks for progress in "state.log", written by mock. Since ~2012, mock changed from writing "State Changed:" in the log. Example of current state.log: 2021-12-06 13:40:36,897 - Mock Version: 1.2.17 2021-12-06 13:40:37,074 - Start: yum install 2021-12-06 13:43:46,593 - Finish: yum install 2021-12-06 13:43:48,038 - Start: creating cache 2021-12-06 13:43:57,480 - Finish: creating cache 2021-12-06 13:43:57,482 - Finish: chroot init 2021-12-06 13:43:57,579 - Start: buildsrpm 2021-12-06 13:43:57,780 - Start: rpmbuild -bs 2021-12-06 13:43:57,972 - Finish: rpmbuild -bs 2021-12-06 13:43:57,977 - Finish: buildsrpm 2021-12-06 13:43:57,978 - Start: clean chroot 2021-12-06 13:44:03,010 - Finish: clean chroot 2021-12-06 13:44:03,011 - Finish: run So now, look for "Start:" and "Finish:" lines and update the build steps `descriptionSuffix` accordingly.
5788897
to
1d0d175
Compare
Done, and rebased on top of |
Codecov Report
@@ Coverage Diff @@
## master #6316 +/- ##
=======================================
Coverage 91.99% 91.99%
=======================================
Files 335 335
Lines 37581 37584 +3
=======================================
+ Hits 34571 34574 +3
Misses 3010 3010
Continue to review full report at Codecov.
|
This fixes the build step summary so that it updates nicely, for example
"mock buildsrpm [dnf install]" when Mock step is running.
Fix MockStateObserver that looks for progress in "state.log", written by
mock. Since ~2012, mock changed from writing "State Changed:" in the
log. Example of current state.log:
So now, look for "Start:" and "Finish:" lines and update the build steps
descriptionSuffix
accordingly.Contributor Checklist:
newsfragments
directory (and read theREADME.txt
in that directory)