Add comprehensive logging to debug slow job completion

- Add timestamps to prepare.ts completion
- Add timestamps and signal handlers to both MCP servers
- Add start/end logging to update-comment-link.ts
- Add final action completion logging step
- Log when composite action steps complete vs job cleanup
This commit is contained in:
claude
2025-07-29 22:41:27 +00:00
parent b570f2eb8e
commit 308512548e
5 changed files with 52 additions and 4 deletions

View File

@@ -111,6 +111,12 @@ runs:
ANTHROPIC_API_KEY: ${{ inputs.anthropic_api_key != 'use-oauth' && inputs.anthropic_api_key || '' }}
CLAUDE_CREDENTIALS: ${{ inputs.claude_credentials }}
- name: Log before Claude Code
if: steps.prepare.outputs.contains_trigger == 'true'
shell: bash
run: |
echo "[$(date -u +%Y-%m-%dT%H:%M:%S.%3NZ)] Starting Claude Code base action..."
- name: Run Claude Code
id: claude-code
if: steps.prepare.outputs.contains_trigger == 'true'
@@ -165,6 +171,13 @@ runs:
VERTEX_REGION_CLAUDE_3_5_SONNET: ${{ env.VERTEX_REGION_CLAUDE_3_5_SONNET }}
VERTEX_REGION_CLAUDE_3_7_SONNET: ${{ env.VERTEX_REGION_CLAUDE_3_7_SONNET }}
- name: Log after Claude Code
if: steps.prepare.outputs.contains_trigger == 'true' && always()
shell: bash
run: |
echo "[$(date -u +%Y-%m-%dT%H:%M:%S.%3NZ)] Claude Code base action completed with status: ${{ steps.claude-code.outcome }}"
echo "[$(date -u +%Y-%m-%dT%H:%M:%S.%3NZ)] Starting comment update..."
- name: Update comment with job link
if: steps.prepare.outputs.contains_trigger == 'true' && steps.prepare.outputs.claude_comment_id && always()
shell: bash
@@ -200,3 +213,10 @@ runs:
else
echo "⚠️ Claude Code execution completed but no report file was generated" >> $GITHUB_STEP_SUMMARY
fi
- name: Log action completion
if: always()
shell: bash
run: |
echo "[$(date -u +%Y-%m-%dT%H:%M:%S.%3NZ)] Claude Code Action composite steps completed"
echo "[$(date -u +%Y-%m-%dT%H:%M:%S.%3NZ)] Waiting for job cleanup..."