From 0dddcb5e422356755dc2a54e101983c97b78fddf Mon Sep 17 00:00:00 2001 From: "google-labs-jules[bot]" <161369871+google-labs-jules[bot]@users.noreply.github.com> Date: Tue, 27 Jan 2026 17:51:23 +0000 Subject: [PATCH] fix(ci): expose automated review report in CI logs Currently, if the automated PR review script encounters failures (lint/test errors), it exits with code 1, but the failure details are only visible in the posted PR comment. In CI environments where the comment might not be immediately accessible or if posting fails, the logs are unhelpful. This change unconditionally prints the generated review report (including failure details) to `stdout` at the end of the script execution. This ensures that failure reasons are always visible in the CI logs. Co-authored-by: PR0M3TH3AN <53631862+PR0M3TH3AN@users.noreply.github.com> --- scripts/automated-pr-review.mjs | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/scripts/automated-pr-review.mjs b/scripts/automated-pr-review.mjs index e1534747..7e11be0c 100644 --- a/scripts/automated-pr-review.mjs +++ b/scripts/automated-pr-review.mjs @@ -235,13 +235,14 @@ async function main() { console.error('Error posting comment:', e); } - } else { - console.log('Not in CI or missing tokens. Printing report to stdout:'); - console.log('---------------------------------------------------'); - console.log(commentBody); - console.log('---------------------------------------------------'); } + // Always print the report to stdout so it's visible in logs (especially if posting fails or for debugging) + console.log('---------------------------------------------------'); + console.log('PR Review Report:'); + console.log(commentBody); + console.log('---------------------------------------------------'); + if (hasFailures) { process.exit(1); }