Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F10682
checkbug46723.py
Public
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Authored By
•
bzimport
Nov 22 2014, 1:30 AM
2014-11-22 01:30:51 (UTC+0)
Size
868 B
Referenced Files
None
Subscribers
None
checkbug46723.py
View Options
import
glob
import
re
re_checkedout
=
re
.
compile
(
r'.*Checking out Revision (\w+).*'
,
re
.
DOTALL
)
re_zuul_commit
=
re
.
compile
(
r'.*ZUUL_COMMIT=(\w+) .*'
,
re
.
DOTALL
)
log_files
=
glob
.
glob
(
'/var/lib/jenkins/jobs/mediawiki-core-phpunit-misc/builds/52??/log'
)
log_files
.
sort
()
for
log_file
in
log_files
:
print
"Verifying
%s
"
%
log_file
file
=
open
(
log_file
)
content
=
file
.
read
()
file
.
close
()
checked_out
=
zuul_commit
=
None
match
=
re_checkedout
.
match
(
content
)
if
match
:
checked_out
=
match
.
groups
()[
0
]
else
:
print
"ERR> could not find checked out revision"
match
=
re_zuul_commit
.
match
(
content
)
if
match
:
zuul_commit
=
match
.
groups
()[
0
]
else
:
print
"ERR> could not find Zuul commit"
mismatch
=
''
if
zuul_commit
!=
checked_out
:
mismatch
=
' (MISMATCH)'
print
"Zuulcommit:
%s
\n
Checkedout:
%s%s
"
%
(
zuul_commit
,
checked_out
,
mismatch
)
File Metadata
Details
Attached
Mime Type
text/plain
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
10160
Default Alt Text
checkbug46723.py (868 B)
Attached To
Mode
T48723: Jenkins merged a faulty change
Attached
Detach File
Event Timeline
Log In to Comment