fix(ci): fix RPC health check workflow failures (#149)
* fix(ci): capture exit code correctly in RPC health check workflow
GitHub Actions `shell: bash` implicitly uses `set -eo pipefail`. The
previous `set -o pipefail` was redundant, and `set -e` caused the shell
to exit immediately when the health check script returned non-zero,
before `exit_code=${PIPESTATUS[0]}` could run. This meant the exit_code
output was never set, so the conditional issue-creation steps (for RPC
mismatch or auth failure) never fired.
Fix: use `set +e` before the pipeline so the script's exit code is
captured into PIPESTATUS, then `set -e` to restore strict mode.
https://claude.ai/code/session_01Bbbf9yHDaWv6gvvqEZwZqH
* fix(ci): replace removed LIST_CONVERSATIONS with GET_LAST_CONVERSATION_ID in health check
LIST_CONVERSATIONS was renamed to GET_LAST_CONVERSATION_ID and
GET_CONVERSATION_TURNS in the chat refactor (#141). The health check
script still referenced the old name, causing an AttributeError.
https://claude.ai/code/session_01Bbbf9yHDaWv6gvvqEZwZqH
* chore(ci): remove redundant set -e in health check workflow
The only statements after exit_code capture are echo and exit,
so restoring strict mode adds no value.
https://claude.ai/code/session_01Bbbf9yHDaWv6gvvqEZwZqH
---------
Co-authored-by: Claude <noreply@anthropic.com>
This commit is contained in:
parent
bc30a3d97b
commit
7939795fa2
2 changed files with 5 additions and 2 deletions
2
.github/workflows/rpc-health.yml
vendored
2
.github/workflows/rpc-health.yml
vendored
|
|
@ -44,7 +44,7 @@ jobs:
|
|||
NOTEBOOKLM_READ_ONLY_NOTEBOOK_ID: ${{ secrets.NOTEBOOKLM_READ_ONLY_NOTEBOOK_ID }}
|
||||
NOTEBOOKLM_GENERATION_NOTEBOOK_ID: ${{ secrets.NOTEBOOKLM_GENERATION_NOTEBOOK_ID }}
|
||||
run: |
|
||||
set -o pipefail
|
||||
set +e
|
||||
python scripts/check_rpc_health.py --full 2>&1 | tee health-report.txt
|
||||
exit_code=${PIPESTATUS[0]}
|
||||
echo "exit_code=${exit_code}" >> "$GITHUB_OUTPUT"
|
||||
|
|
|
|||
|
|
@ -434,12 +434,15 @@ def get_test_params(method: RPCMethod, notebook_id: str | None) -> list[Any] | N
|
|||
|
||||
# Methods that take [[notebook_id]] as the only param
|
||||
if method in (
|
||||
RPCMethod.LIST_CONVERSATIONS,
|
||||
RPCMethod.GET_NOTES_AND_MIND_MAPS,
|
||||
RPCMethod.DISCOVER_SOURCES,
|
||||
):
|
||||
return [[notebook_id]]
|
||||
|
||||
# GET_LAST_CONVERSATION_ID: returns most recent conversation ID
|
||||
if method == RPCMethod.GET_LAST_CONVERSATION_ID:
|
||||
return [[], None, notebook_id, 1]
|
||||
|
||||
# GET_CONVERSATION_TURNS: placeholder conv ID - API echoes RPC ID even in error response
|
||||
if method == RPCMethod.GET_CONVERSATION_TURNS:
|
||||
return [[], None, None, "placeholder_conv_id", 2]
|
||||
|
|
|
|||
Loading…
Reference in a new issue