Merge pull request #112 from SanjulaGanepola/fix/matrix-job-status
Fix matrix job for when workflow jobs have no name
This commit is contained in:
@@ -455,14 +455,14 @@ export class Act {
|
|||||||
if (parsedMessage.jobID in commandArgs.workflow.yaml.jobs && commandArgs.workflow.yaml.jobs[parsedMessage.jobID].name) {
|
if (parsedMessage.jobID in commandArgs.workflow.yaml.jobs && commandArgs.workflow.yaml.jobs[parsedMessage.jobID].name) {
|
||||||
// Use the name set for the job by the user
|
// Use the name set for the job by the user
|
||||||
jobName = commandArgs.workflow.yaml.jobs[parsedMessage.jobID].name;
|
jobName = commandArgs.workflow.yaml.jobs[parsedMessage.jobID].name;
|
||||||
|
}
|
||||||
|
} catch (error: any) { }
|
||||||
|
|
||||||
// Update name if it is a matrix
|
// Update name if it is a matrix
|
||||||
if (parsedMessage.matrix && Object.keys(parsedMessage.matrix).length > 0) {
|
if (parsedMessage.matrix && Object.keys(parsedMessage.matrix).length > 0) {
|
||||||
const matrixValues = Object.values(parsedMessage.matrix).join(", ");
|
const matrixValues = Object.values(parsedMessage.matrix).join(", ");
|
||||||
jobName = `${jobName} (${matrixValues})`;
|
jobName = `${jobName} (${matrixValues})`;
|
||||||
}
|
}
|
||||||
}
|
|
||||||
} catch (error: any) { }
|
|
||||||
|
|
||||||
let jobIndex = this.historyManager.workspaceHistory[commandArgs.path][historyIndex].jobs!
|
let jobIndex = this.historyManager.workspaceHistory[commandArgs.path][historyIndex].jobs!
|
||||||
.findIndex(job => job.name === jobName);
|
.findIndex(job => job.name === jobName);
|
||||||
|
|||||||
Reference in New Issue
Block a user