Skip to content

Commit d6641de

Browse files
authored
chore(ci): fix gardener issues comment workflow pt 2 (#17886)
We were no longer getting the `item_id`
1 parent f69fc6a commit d6641de

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

.github/workflows/gardener_issue_comment.yml

+5-1
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@ jobs:
2020
GH_TOKEN: ${{ secrets.GH_PROJECT_PAT }}
2121
run: |
2222
issue_id=${{ github.event.issue.node_id }}
23+
echo "issue_id: $issue_id"
2324
2425
# IDs fetched from https://docs.github.com/en/graphql/overview/explorer
2526
project_id="PVT_kwDOAQFeYs4AAsTr" # Gardener
@@ -40,6 +41,7 @@ jobs:
4041
}
4142
}
4243
... on ProjectV2Item {
44+
id
4345
project {
4446
... on ProjectV2 {
4547
id
@@ -55,7 +57,9 @@ jobs:
5557
)"
5658
5759
# Extract the item in the Gardener project
58-
current_status=$(echo $project_items | jq -c -r --arg project_id $project_id '.data.node.projectItems.nodes[] | select(.project.id == $project_id) | .fieldValueByName.name')
60+
project=$(echo $project_items | jq -c -r --arg project_id $project_id '.data.node.projectItems.nodes[] | select(.project.id == $project_id)')
61+
current_status=$(echo $project | jq -c '.fieldValueByName.name')
62+
item_id=$(echo $project | jq -c '.id')
5963
6064
if [ -z "$current_status" ] ; then
6165
echo "Issue not found in Gardener board"

0 commit comments

Comments
 (0)