mirror of
https://github.com/ROCm/composable_kernel.git
synced 2026-04-19 22:39:03 +00:00
[rocm-libraries] ROCm/rocm-libraries#4352 (commit 3c9beb3)
[CK] MICI: Fix git diff in selective_test_filter.py ## Motivation - git diff needs access to reference repo ## Technical Details - mount reference repo path into docker for selective_test_filter.py to access ## Test Plan - tested in MICI ## Test Result - launch_tests.sh ran successfully
This commit is contained in:
committed by
assistant-librarian[bot]
parent
58549aa787
commit
e96beb1f3e
6
Jenkinsfile
vendored
6
Jenkinsfile
vendored
@@ -484,7 +484,7 @@ def get_docker_options(){
|
||||
// on some machines the group ids for video and render groups may not be the same as in the docker image!
|
||||
def video_id = sh(returnStdout: true, script: 'getent group video | cut -d: -f3')
|
||||
def render_id = sh(returnStdout: true, script: 'getent group render | cut -d: -f3')
|
||||
dockerOpts = dockerOpts + " --group-add=${video_id} --group-add=${render_id} "
|
||||
dockerOpts = dockerOpts + " --group-add=${video_id} --group-add=${render_id} -v /var/jenkins/ref-repo/:/var/jenkins/ref-repo/ "
|
||||
echo "Docker flags: ${dockerOpts}"
|
||||
return dockerOpts
|
||||
}
|
||||
@@ -1294,8 +1294,8 @@ pipeline {
|
||||
description: "Run CK_BUILDER tests (default: ON)")
|
||||
booleanParam(
|
||||
name: "RUN_ALL_UNIT_TESTS",
|
||||
defaultValue: true,
|
||||
description: "Run all unit tests (default: ON)")
|
||||
defaultValue: false,
|
||||
description: "Run all unit tests (default: OFF)")
|
||||
booleanParam(
|
||||
name: "RUN_PYTORCH_TESTS",
|
||||
defaultValue: false,
|
||||
|
||||
@@ -34,6 +34,13 @@ import os
|
||||
def get_changed_files(ref1, ref2):
|
||||
"""Return a set of files changed between two git refs."""
|
||||
try:
|
||||
result = subprocess.run(
|
||||
["pwd"],
|
||||
capture_output=True,
|
||||
text=True,
|
||||
check=True,
|
||||
)
|
||||
print("cwd:", result.stdout)
|
||||
result = subprocess.run(
|
||||
["git", "diff", "--name-only", ref1, ref2],
|
||||
capture_output=True,
|
||||
@@ -43,7 +50,9 @@ def get_changed_files(ref1, ref2):
|
||||
files = set(line.strip() for line in result.stdout.splitlines() if line.strip())
|
||||
return files
|
||||
except subprocess.CalledProcessError as e:
|
||||
print(f"Error running git diff: {e}")
|
||||
print(f"Command '{e.cmd}' returned non-zero exit status {e.returncode}.")
|
||||
print(f"Error output: {e.stderr}")
|
||||
print(f"Standard output: {e.stdout}")
|
||||
sys.exit(1)
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user