Skip to content

Commit 54ec031

Browse files
authored
[HUD] Add repro command for gpu-dev (#7424)
Add button for gpu dev instructions Add instructions for gpu-dev <img width="408" height="82" alt="image" src="https://github.com/user-attachments/assets/cfa85929-04b0-41d9-8253-7241ddfdf3e9" /> <img width="1018" height="928" alt="image" src="https://github.com/user-attachments/assets/9a8a0c0e-d3b1-47e8-9f59-8849ce7eb5a8" />
1 parent 62d0084 commit 54ec031

File tree

2 files changed

+443
-0
lines changed

2 files changed

+443
-0
lines changed

torchci/components/job/JobLinks.tsx

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ import { useSession } from "next-auth/react";
1212
import { IssueLabelApiResponse } from "pages/api/issue/[label]";
1313
import useSWR from "swr";
1414
import styles from "./JobLinks.module.css";
15+
import { ODCommandInstructions } from "./ODCCommand";
1516
import ReproductionCommand from "./ReproductionCommand";
1617

1718
const DEFAULT_REPO = "pytorch/pytorch";
@@ -129,6 +130,28 @@ export default function JobLinks({
129130
}
130131
}
131132

133+
if (
134+
job.repo == "pytorch/pytorch" &&
135+
isFailedJob(job) &&
136+
job.workflowId != null &&
137+
job.id != null &&
138+
job.failureLineNumbers &&
139+
job.failureLineNumbers.length > 0 &&
140+
job.sha != null &&
141+
job.name?.includes("linux") // ODC only supports linux jobs for now
142+
) {
143+
const ODCCommand = ODCommandInstructions({
144+
jobId: parseInt(job.id),
145+
workflowId: parseInt(job.workflowId),
146+
failureLineNum: job.failureLineNumbers[0],
147+
headSha: job.sha,
148+
jobName: job.name,
149+
});
150+
if (ODCCommand != null) {
151+
subInfo.push(ODCCommand);
152+
}
153+
}
154+
132155
return (
133156
<span>
134157
{subInfo.map((info, i) => (

0 commit comments

Comments
 (0)