-
Notifications
You must be signed in to change notification settings - Fork 85
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
Git Bisection Automated for build of a kernel #810
Conversation
testcases/Build_bisector.py
Outdated
Test case for bisecting the Linux kernel using Git Bisect. | ||
This test downloads the Linux kernel from a specified repository, | ||
configures and compiles it, and then uses Git Bisect to find the | ||
commit that introduced a specific issue. |
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.
s/specific issue/build failure/ will be apt
4e913ee
to
b303489
Compare
6605c90
to
d575d90
Compare
7844a49
to
ec27074
Compare
test_binaries/make.sh
Outdated
@@ -0,0 +1,23 @@ | |||
#!/usr/bin/env python3 |
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.
since this is a shell script, this python related line is not required. Remove 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.
@Tejas3772 this is not yet done
test_binaries/make.sh
Outdated
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or | ||
# implied. See the License for the specific language governing | ||
# permissions and limitations under the License. | ||
#!/bin/bash |
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.
Move this to the top of file.
0fa3418
to
df05273
Compare
several changes made and linux-next functionalities added |
5565e32
to
e28cc92
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.
Look at the review comments once again.. I do not see it in the latest code
test_binaries/make.sh
Outdated
@@ -0,0 +1,23 @@ | |||
#!/usr/bin/env python3 |
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.
@Tejas3772 this is not yet done
b8aefee
to
5c0209b
Compare
Signed-off-by: Tejas Manhas <Tejas.Manhas@ibm.com>
…r multiple uses Signed-off-by: Tejas Manhas <Tejas.Manhas@ibm.com>
944e722
to
7f71edf
Compare
…or if build faiils Signed-off-by: Tejas Manhas <Tejas.Manhas@ibm.com>
Signed-off-by: Tejas Manhas <Tejas.Manhas@ibm.com>
from common.OpTestSOL import OpSOLMonitorThread | ||
from common.OpTestInstallUtil import InstallUtil | ||
from common.Exceptions import CommandFailed | ||
import test_binaries |
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.
move import to above and arrange all imports in alphabaticle order
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.
and add one empty line below
self.console_thread = OpSOLMonitorThread(1, "console") | ||
self.host_cmd_timeout = self.conf.args.host_cmd_timeout | ||
self.repo = self.conf.args.git_repo | ||
self.repo_reference = self.conf.args.git_repo_reference |
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 2 params for repo ?
self.branch = self.conf.args.git_branch | ||
self.home = self.conf.args.git_home | ||
self.config_path = self.conf.args.git_repoconfigpath | ||
self.config = self.conf.args.git_repoconfig |
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.
it can be single config parameter that can take both path or http link
self.config = self.conf.args.git_repoconfig | ||
self.good_commit = self.conf.args.good_commit | ||
self.bad_commit = self.conf.args.bad_commit | ||
self.bisect_script = self.conf.args.bisect_script |
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 we need script parameter ?
PPC KBOT | ||
""".format(gcc_version, machine_type, error_message,kernel_version, machine_type, gcc_version, commit,commit, commit, fix_description) | ||
print(subject) | ||
print(body) |
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.
is print require or for debug only .. you decide to keep or remove
|
||
with open("email.json","w") as email: | ||
json.dump({"subject":subject,"body":body},email) | ||
# return subject, body |
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.
you should uncomment ? or remove
# distributed under the License is distributed on an "AS IS" BASIS, | ||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or | ||
# implied. See the License for the specific language governing | ||
# permissions and limitations under the License. |
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.
add empty line below and Author name and mail id
from testcases import Email_git | ||
from common.OpTestSystem import OpSystemState | ||
from common.OpTestSOL import OpSOLMonitorThread | ||
from common.Exceptions import CommandFailed |
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.
add empty line beflore and 2 empty lines after log line
""" | ||
Build and install the Linux kernel. | ||
""" | ||
self.connection.run_command("wget http://ltc-jenkins.aus.stglabs.ibm.com:81/abdul/ioci/kernel_config -o linux/.config") |
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.
remove the config link
A new PR is created #849 Which inlcudes all the review comments implemented discussed above and more integrated code some of the recent review comments
Once build PR merge, rebase your code and send boot bisection code with new PR |
new pr merged |
Description
This Pull Request includes a Test_build.py that builds the kernel while checking for build failure, if a build failure is found it directly calls Build_bisector.py that runs the bisection for build using the make.sh file from the test_binaries and finally if the bisection occurred, it returns an output.json file containing the first bad_commit, the email of the Author associated with the commit, failure directory and exit code.