cicd runtime_error ai_generated partial

错误:工作流在等待审批 60 分钟后超时。工作流已被取消。

Error: Workflow timed out after 60 minutes waiting for approval. The workflow has been canceled.

ID: cicd/circleci-workflow-approval-timeout

其他格式: JSON · Markdown 中文 · English
88%修复率
83%置信度
1证据数
2024-06-12首次发现

版本兼容性

版本状态引入弃用备注
CircleCI CLI 0.1.3000 active
CircleCI Server 4.0 active

根因分析

由于所需的审批者在默认的 60 分钟超时时间内未批准或拒绝作业,带有手动审批作业的 CircleCI 工作流超时。

English

A CircleCI workflow with a manual approval job timed out because the required approver did not approve or reject the job within the default 60-minute timeout period.

generic

官方文档

https://circleci.com/docs/workflows/#holding-a-workflow-for-manual-approval

解决方案

  1. Use the CircleCI API to approve the job manually: `curl -X POST -H "Circle-Token: $CIRCLE_TOKEN" https://circleci.com/api/v2/workflow/{workflow_id}/approve/{approval_request_id}`. Find the approval_request_id from the workflow's jobs via the API.
  2. Modify the workflow configuration to remove the approval job for non-production branches, or use a conditional approval: `when: << pipeline.parameters.deploy_to_prod >>` where the parameter defaults to false for development branches.

无效尝试

常见但无效的做法:

  1. 90% 失败

    Project settings do not control approval timeout; the timeout is fixed per plan (60 minutes for free/paid) and cannot be changed via settings.

  2. 85% 失败

    Re-running does not bypass the approval step; the same approval job will be triggered again, and the timeout will recur if no one approves.