feat: 优化跳过步骤逻辑,确保步骤 1 跳过时同时跳过步骤 2

This commit is contained in:
QLHazyCoder
2026-04-08 17:45:19 +08:00
parent ce78a099d6
commit 237980037b
+10
View File
@@ -666,6 +666,16 @@ async function skipStep(step) {
await setStepStatus(step, 'skipped');
await addLog(`步骤 ${step} 已跳过`, 'warn');
if (step === 1) {
const latestState = await getState();
const step2Status = latestState.stepStatuses?.[2];
if (!isStepDoneStatus(step2Status) && step2Status !== 'running') {
await setStepStatus(2, 'skipped');
await addLog('步骤 1 已跳过,步骤 2 也已同时跳过。', 'warn');
}
}
return { ok: true, step, status: 'skipped' };
}