File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -15,11 +15,16 @@ jobs:
1515 - name : Prepare requirement data
1616 id : requirement
1717 run : |
18- ENHANCED_TASK="${{ github.event.client_payload.task }}"
19- ORIGINAL_TASK="${{ github.event.client_payload.original_task }}"
20- REQUESTER="${{ github.event.client_payload.requester }}"
21- TIMESTAMP="${{ github.event.client_payload.timestamp }}"
22- PREPROCESSING_RUN_ID="${{ github.event.client_payload.preprocessing_run_id }}"
18+ # Use jq to safely extract values from event payload to avoid shell quoting issues
19+ # Write event payload to temp file first
20+ echo '${{ toJSON(github.event.client_payload) }}' > /tmp/event_payload.json
21+
22+ # Extract values using jq (handles all escaping automatically)
23+ ENHANCED_TASK=$(jq -r '.task // .original_task // ""' /tmp/event_payload.json)
24+ ORIGINAL_TASK=$(jq -r '.original_task // .task // ""' /tmp/event_payload.json)
25+ REQUESTER=$(jq -r '.requester // ""' /tmp/event_payload.json)
26+ TIMESTAMP=$(jq -r '.timestamp // ""' /tmp/event_payload.json)
27+ PREPROCESSING_RUN_ID=$(jq -r '.preprocessing_run_id // ""' /tmp/event_payload.json)
2328
2429 # Generate a title from the enhanced task (first line or first 100 chars)
2530 TITLE=$(echo "$ENHANCED_TASK" | head -n 1 | cut -c 1-100)
You can’t perform that action at this time.
0 commit comments