github-actions[bot] commented on code in PR #65626:
URL: https://github.com/apache/doris/pull/65626#discussion_r3585227423


##########
.github/workflows/code-review-runner.yml:
##########
@@ -660,22 +663,26 @@ jobs:
             and (.tokens.access_token | type == "string" and length > 0)
             and (.tokens.refresh_token | type == "string" and length > 0)
           ' "$CODEX_HOME/auth.json" >/dev/null
-          ossutil -i "$OSS_AK" -k "$OSS_SK" -e "$OSS_ENDPOINT" cp -f 
"$CODEX_HOME/auth.json" "$OSS_CODEX_AUTH_OBJECT"
+          ossutil -i "$OSS_AK" -k "$OSS_SK" -e "$OSS_ENDPOINT" cp -f 
"$CODEX_HOME/auth.json" "$CODEX_AUTH_OSS_OBJECT"
         env:
           OSS_AK: ${{ secrets.OSS_AK }}
           OSS_SK: ${{ secrets.OSS_SK }}
           OSS_ENDPOINT: oss-cn-hongkong.aliyuncs.com
-          OSS_CODEX_AUTH_OBJECT: oss://doris-community-ci/codex/auth.json
 
       - name: Comment PR on review failure
-        if: ${{ always() && steps.review.outcome != 'success' }}
+        if: ${{ always() && (steps.review_context.outcome != 'success' || 
steps.review.outcome != 'success') }}
         env:
           GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
+          REVIEW_CONTEXT_OUTCOME: ${{ steps.review_context.outcome }}
           REVIEW_FAILURE_REASON: ${{ steps.review.outputs.failure_reason }}
           REVIEW_OUTCOME: ${{ steps.review.outcome }}
           RUN_URL: ${{ github.server_url }}/${{ github.repository 
}}/actions/runs/${{ github.run_id }}
         run: |
-          error_msg="${REVIEW_FAILURE_REASON:-Review step was $REVIEW_OUTCOME 
(possibly timeout or cancelled)}"
+          if [ "$REVIEW_CONTEXT_OUTCOME" != "success" ]; then
+            error_msg="Review context preparation failed before Codex ran; 
inspect the 'Prepare authoritative PR context and required AGENTS guides' step."
+          else
+            error_msg="${REVIEW_FAILURE_REASON:-Review step was 
$REVIEW_OUTCOME (possibly timeout or cancelled)}"
+          fi

Review Comment:
   This branch also catches the case where `review_context` never ran. If any 
earlier required setup step fails, GitHub skips `review_context`, so 
`steps.review_context.outcome` is `skipped`; the `always()` failure handler 
then tells maintainers that context preparation failed and points them at this 
step, masking the actual failed setup step. Please distinguish `failure` from 
`skipped`/`cancelled` here, or use a generic earlier-setup-failed message when 
`review_context` was skipped.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to