






















@@ -275,7 +275,7 @@ jobs:
275275 local workflow="$1"
276276 shift
277277278- local before_json dispatch_output run_id status conclusion url poll_count
278+ local dispatch_output run_id status conclusion url poll_count
279279 gh_with_retry() {
280280 local output status attempt
281281 for attempt in 1 2 3 4 5 6; do
@@ -298,8 +298,6 @@ jobs:
298298 printf '%s\n' "$output" >&2
299299 return "$status"
300300 }
301- before_json="$(gh_with_retry run list --workflow "$workflow" --event workflow_dispatch --limit 100 --json databaseId --jq '[.[].databaseId]')"
302-303301 dispatch_output="$(gh_with_retry workflow run "$workflow" --ref "$CHILD_WORKFLOW_REF" "$@")"
304302 printf '%s\n' "$dispatch_output"
305303 run_id="$(
@@ -309,20 +307,7 @@ jobs:
309307 )"
310308311309 if [[ -z "$run_id" ]]; then
312- for _ in $(seq 1 60); do
313- run_id="$(
314- BEFORE_IDS="$before_json" gh_with_retry run list --workflow "$workflow" --event workflow_dispatch --limit 50 --json databaseId,createdAt \
315- --jq 'map(select(.databaseId as $id | (env.BEFORE_IDS | fromjson | index($id) | not))) | sort_by(.createdAt) | reverse | .[0].databaseId // empty'
316- )"
317- if [[ -n "$run_id" ]]; then
318- break
319- fi
320- sleep 5
321- done
322- fi
323-324- if [[ -z "${run_id:-}" ]]; then
325- echo "Could not find dispatched run for ${workflow}." >&2
310+ echo "::error::gh workflow run ${workflow} did not return an Actions run URL; refusing to guess from recent workflow_dispatch runs." >&2
326311 exit 1
327312 fi
328313@@ -423,7 +408,7 @@ jobs:
423408 local workflow="$1"
424409 shift
425410426- local before_json dispatch_output run_id status conclusion url poll_count
411+ local dispatch_output run_id status conclusion url poll_count
427412 gh_with_retry() {
428413 local output status attempt
429414 for attempt in 1 2 3 4 5 6; do
@@ -446,8 +431,6 @@ jobs:
446431 printf '%s\n' "$output" >&2
447432 return "$status"
448433 }
449- before_json="$(gh_with_retry run list --workflow "$workflow" --event workflow_dispatch --limit 100 --json databaseId --jq '[.[].databaseId]')"
450-451434 dispatch_output="$(gh_with_retry workflow run "$workflow" --ref "$CHILD_WORKFLOW_REF" "$@")"
452435 printf '%s\n' "$dispatch_output"
453436 run_id="$(
@@ -457,20 +440,7 @@ jobs:
457440 )"
458441459442 if [[ -z "$run_id" ]]; then
460- for _ in $(seq 1 60); do
461- run_id="$(
462- BEFORE_IDS="$before_json" gh_with_retry run list --workflow "$workflow" --event workflow_dispatch --limit 50 --json databaseId,createdAt \
463- --jq 'map(select(.databaseId as $id | (env.BEFORE_IDS | fromjson | index($id) | not))) | sort_by(.createdAt) | reverse | .[0].databaseId // empty'
464- )"
465- if [[ -n "$run_id" ]]; then
466- break
467- fi
468- sleep 5
469- done
470- fi
471-472- if [[ -z "${run_id:-}" ]]; then
473- echo "Could not find dispatched run for ${workflow}." >&2
443+ echo "::error::gh workflow run ${workflow} did not return an Actions run URL; refusing to guess from recent workflow_dispatch runs." >&2
474444 exit 1
475445 fi
476446@@ -581,7 +551,7 @@ jobs:
581551 local workflow="$1"
582552 shift
583553584- local before_json dispatch_output run_id status conclusion url poll_count run_json
554+ local dispatch_output run_id status conclusion url poll_count run_json
585555 gh_with_retry() {
586556 local output status attempt
587557 for attempt in 1 2 3 4 5 6; do
@@ -604,8 +574,6 @@ jobs:
604574 printf '%s\n' "$output" >&2
605575 return "$status"
606576 }
607- before_json="$(gh_with_retry run list --workflow "$workflow" --event workflow_dispatch --limit 100 --json databaseId --jq '[.[].databaseId]')"
608-609577 dispatch_output="$(gh_with_retry workflow run "$workflow" --ref "$CHILD_WORKFLOW_REF" "$@")"
610578 printf '%s\n' "$dispatch_output"
611579 run_id="$(
@@ -615,20 +583,7 @@ jobs:
615583 )"
616584617585 if [[ -z "$run_id" ]]; then
618- for _ in $(seq 1 60); do
619- run_id="$(
620- BEFORE_IDS="$before_json" gh_with_retry run list --workflow "$workflow" --event workflow_dispatch --limit 50 --json databaseId,createdAt \
621- --jq 'map(select(.databaseId as $id | (env.BEFORE_IDS | fromjson | index($id) | not))) | sort_by(.createdAt) | reverse | .[0].databaseId // empty'
622- )"
623- if [[ -n "$run_id" ]]; then
624- break
625- fi
626- sleep 5
627- done
628- fi
629-630- if [[ -z "${run_id:-}" ]]; then
631- echo "Could not find dispatched run for ${workflow}." >&2
586+ echo "::error::gh workflow run ${workflow} did not return an Actions run URL; refusing to guess from recent workflow_dispatch runs." >&2
632587 exit 1
633588 fi
634589@@ -928,8 +883,6 @@ jobs:
928883 return "$status"
929884 }
930885931- before_json="$(gh_with_retry run list --workflow npm-telegram-beta-e2e.yml --event workflow_dispatch --limit 100 --json databaseId --jq '[.[].databaseId]')"
932-933886 args=(-f package_spec="${PACKAGE_SPEC:-openclaw@beta}" -f harness_ref="$TARGET_SHA" -f provider_mode="$PROVIDER_MODE")
934887 if [[ -z "${PACKAGE_SPEC// }" ]]; then
935888 if [[ "$PREPARE_PACKAGE_RESULT" != "success" || -z "${PACKAGE_ARTIFACT_NAME// }" ]]; then
@@ -946,22 +899,16 @@ jobs:
946899 args+=(-f scenario="$SCENARIO")
947900 fi
948901949- gh_with_retry workflow run npm-telegram-beta-e2e.yml --ref "$CHILD_WORKFLOW_REF" "${args[@]}"
950-951- run_id=""
952- for _ in $(seq 1 60); do
953- run_id="$(
954- BEFORE_IDS="$before_json" gh_with_retry run list --workflow npm-telegram-beta-e2e.yml --event workflow_dispatch --limit 50 --json databaseId,createdAt \
955- --jq 'map(select(.databaseId as $id | (env.BEFORE_IDS | fromjson | index($id) | not))) | sort_by(.createdAt) | reverse | .[0].databaseId // empty'
956- )"
957- if [[ -n "$run_id" ]]; then
958- break
959- fi
960- sleep 5
961- done
902+ dispatch_output="$(gh_with_retry workflow run npm-telegram-beta-e2e.yml --ref "$CHILD_WORKFLOW_REF" "${args[@]}")"
903+ printf '%s\n' "$dispatch_output"
904+ run_id="$(
905+ printf '%s\n' "$dispatch_output" |
906+ sed -nE 's#.*actions/runs/([0-9]+).*#\1#p' |
907+ tail -n 1
908+ )"
962909963910 if [[ -z "$run_id" ]]; then
964- echo "Could not find dispatched run for npm-telegram-beta-e2e.yml." >&2
911+ echo "::error::gh workflow run npm-telegram-beta-e2e.yml did not return an Actions run URL; refusing to guess from recent workflow_dispatch runs." >&2
965912 exit 1
966913 fi
967914@@ -1073,31 +1020,23 @@ jobs:
10731020 echo "- Release impact: advisory"
10741021 } >> "$GITHUB_STEP_SUMMARY"
107510221076- before_json="$(gh_with_retry run list --workflow openclaw-performance.yml --event workflow_dispatch --limit 100 --json databaseId --jq '[.[].databaseId]')"
1077-1078- gh_with_retry workflow run openclaw-performance.yml \
1023+ dispatch_output="$(gh_with_retry workflow run openclaw-performance.yml \
10791024 --ref "$CHILD_WORKFLOW_REF" \
10801025 -f target_ref="$TARGET_SHA" \
10811026 -f profile=release \
10821027 -f repeat=3 \
10831028 -f deep_profile=false \
10841029 -f live_openai_candidate=false \
1085- -f fail_on_regression=false
1086-1087- run_id=""
1088- for _ in $(seq 1 60); do
1089- run_id="$(
1090- BEFORE_IDS="$before_json" gh_with_retry run list --workflow openclaw-performance.yml --event workflow_dispatch --limit 50 --json databaseId,createdAt \
1091- --jq 'map(select(.databaseId as $id | (env.BEFORE_IDS | fromjson | index($id) | not))) | sort_by(.createdAt) | reverse | .[0].databaseId // empty'
1092- )"
1093- if [[ -n "$run_id" ]]; then
1094- break
1095- fi
1096- sleep 5
1097- done
1030+ -f fail_on_regression=false)"
1031+ printf '%s\n' "$dispatch_output"
1032+ run_id="$(
1033+ printf '%s\n' "$dispatch_output" |
1034+ sed -nE 's#.*actions/runs/([0-9]+).*#\1#p' |
1035+ tail -n 1
1036+ )"
1098103710991038 if [[ -z "$run_id" ]]; then
1100- echo "::warning::Could not find dispatched run for openclaw-performance.yml."
1039+ echo "::warning::gh workflow run openclaw-performance.yml did not return an Actions run URL; refusing to guess from recent workflow_dispatch runs."
11011040 exit 0
11021041 fi
11031042此内容由惯性聚合(RSS阅读器)自动聚合整理,仅供阅读参考。 原文来自 — 版权归原作者所有。