You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
query {
node(id: "${{ env.PR_NODE_ID }}") {
... on PullRequest {
projectItems(first: 10) {
nodes {
id
project {
id
}
}
}
}
}
}' > project_data.json
Similarly, we don't need separate steps for an issue or PR to get its project specific ID, we can just modify the above query to include ... on Issue and query that. The output JSON will be the same regardless and downstream mutations don't care if it's a PR or an issue.
Describe alternatives you've considered
No response
Additional context
This saves us graphQL api usage, and it's always good to minimize that since we don't want to get rate limited on a busy day.
The text was updated successfully, but these errors were encountered:
Is this a duplicate?
Area
Infrastructure
Is your feature request related to a problem? Please describe.
The automations are hard to read, partly because graphQL isn't a beautiful query language IMO, and partly because they're inefficient queries.
Describe the solution you'd like
We can and should use the global node IDs of items and query them directly. In action below:
Can be simplified into:
Similarly, we don't need separate steps for an issue or PR to get its project specific ID, we can just modify the above query to include
... on Issue
and query that. The output JSON will be the same regardless and downstream mutations don't care if it's a PR or an issue.Describe alternatives you've considered
No response
Additional context
This saves us graphQL api usage, and it's always good to minimize that since we don't want to get rate limited on a busy day.
The text was updated successfully, but these errors were encountered: