-
Notifications
You must be signed in to change notification settings - Fork 7.9k
Open
Labels
Description
CLI Feedback
I run gh pr create as part of a GitHub Action, after doing a git push before.
It's unexpectedly slow, takes over one minute.
I'm wondering why it's so slow and how I can debug it further and improve it.
Here's the command I run:
gh pr create --draft --reviewer jakub-g --title 'title' --body 'body' --base jakub/test1 --head jakub/test2
(the diff between the branches is a single commit)
When I run with GH_DEBUG=1 I can see a lot of GQL requests, that overall take ~1 minute, but it doesn't help understanding what are those requests:
Wed, 13 Aug 2025 08:51:50 GMT
* Request at 2025-08-13 08:51:50.057562725 +0000 UTC m=+0.558926597
Wed, 13 Aug 2025 08:51:50 GMT
* Request to https://api.github.com/graphql
Wed, 13 Aug 2025 08:51:50 GMT
* Request took 352.609643ms
Wed, 13 Aug 2025 08:51:50 GMT
* Request at 2025-08-13 08:51:50.411168575 +0000 UTC m=+0.912532447
Wed, 13 Aug 2025 08:51:50 GMT
* Request to https://api.github.com/graphql
Wed, 13 Aug 2025 08:51:50 GMT
* Request at 2025-08-13 08:51:50.411248677 +0000 UTC m=+0.912612550
Wed, 13 Aug 2025 08:51:50 GMT
* Request to https://api.github.com/graphql
Wed, 13 Aug 2025 08:51:50 GMT
* Request took 121.577763ms
Wed, 13 Aug 2025 08:51:51 GMT
* Request took 1.281666725s
Wed, 13 Aug 2025 08:51:51 GMT
* Request at 2025-08-13 08:51:51.694308113 +0000 UTC m=+2.195671986
Wed, 13 Aug 2025 08:51:51 GMT
* Request to https://api.github.com/graphql
...
Wed, 13 Aug 2025 08:52:42 GMT
* Request at 2025-08-13 08:52:42.881275406 +0000 UTC m=+53.382639279
Wed, 13 Aug 2025 08:52:42 GMT
* Request to https://api.github.com/graphql
Wed, 13 Aug 2025 08:52:44 GMT
* Request took 1.118918389s
Wed, 13 Aug 2025 08:52:44 GMT
* Request at 2025-08-13 08:52:44.000436367 +0000 UTC m=+54.501800250
Wed, 13 Aug 2025 08:52:44 GMT
* Request to https://api.github.com/graphql
Wed, 13 Aug 2025 08:52:44 GMT
* Request took 774.208449ms
Question
What can I do to debug this further?
Notes
(note: my repo is huge: 1000s of branches, almost 1M commit, not sure if this is relevant)
Reactions are currently unavailable