cli: [Bug]: Process aborts when requests last longer than 15 seconds

Please confirm that you have:

  • Searched existing issues to see if your issue is a duplicate. (If you’ve found a duplicate issue, feel free to add additional information in a comment on it.)
  • Reproduced the issue in the latest CLI version.

In which of these areas are you experiencing a problem?

Theme

Expected behavior

https://shopify.dev/docs/storefronts/themes/getting-started/create I am on the Doc for Getting-started.

Command

shopify theme dev --store XXXXXX

Image

Actual behavior

Running the command “shopify theme dev --store XXXX”. It shows Logged in successful, but after that error msg show “The user aborted a request.”

Image

Verbose output

Verbose output
➜  shopify shopify theme dev --store TGM-Test-Store  

To run this command, log in to Shopify.
User verification code: ZBSW-BMKK
👉 Press any key to open the login page on your browser
Opened link to start the auth process: https://accounts.shopify.com/activate-with-code?device_code%5Buser_code%5D=ZBSW-BMKK
✔ Logged in.
╭─ error ──────────────────────────────────────────────────────────────────────╮
│                                                                              │
│  The user aborted a request.                                                 │
│                                                                              │
╰──────────────────────────────────────────────────────────────────────────────╯

Reproduction steps

The account I used is the store owner, the same email address for developer Partner.

Operating System

Mac Os

Shopify CLI version (shopify --version)

@shopify/cli/3.77.1 darwin-x64 node-v22.14.0

Shell

No response

Node version (run node -v if you’re not sure)

v22.14.0

What language and version are you using in your application?

No response

About this issue

  • Original URL
  • State: closed
  • Created 2 years ago
  • Reactions: 6
  • Comments: 37 (11 by maintainers)

Most upvoted comments

Yup, same here when trying to run a remix app with shopify app dev. Stack trace:

AbortError: The user aborted a request.
    at abort (file:///Users/janpeltner/.nvm/versions/node/v22.14.0/lib/node_modules/@shopify/cli/dist/chunk-7TDJWEEF.js:17571:23)
    at AbortSignal.abortAndFinalize (file:///Users/janpeltner/.nvm/versions/node/v22.14.0/lib/node_modules/@shopify/cli/dist/chunk-7TDJWEEF.js:17579:11)
    at [nodejs.internal.kHybridDispatch] (node:internal/event_target:827:20)
    at AbortSignal.dispatchEvent (node:internal/event_target:762:26)
    at runAbort (node:internal/abort_controller:447:10)
    at abortSignal (node:internal/abort_controller:433:3)
    at Timeout._onTimeout (node:internal/abort_controller:153:7)
    at listOnTimeout (node:internal/timers:594:17)
    at process.processTimers (node:internal/timers:529:7)

CLI version: @shopify/cli/3.77.1 darwin-arm64 node-v22.14.0

EDIT: The issue is fixed for me when I downgrade to the following CLI version: @shopify/cli/3.76.2 darwin-arm64 node-v22.14.0

Maybe it has something to do with this CLI-Kit feature that’s been introduced with 3.77.0? 👀

Automatic cancellation of slow network requests

Why this issue is closed?

@EvilGenius13 there’s another user facing this error when running theme dev with the latest version. This is what the verbose log shows:

2025-05-12T20:08:14.805Z: File Upload Results:
-config/settings_data.json: success
2025-05-12T20:08:23.926Z: Retrying request to https://xxx.myshopify.com/admin/api/2025-04/graphql.json due to network error FetchError: request to https://xxx.myshopify.com/admin/api/2025-04/graphql.json failed, reason: socket hang up
2025-05-12T20:08:23.926Z: Request to https://xxx.myshopify.com/admin/api/2025-04/graphql.json completed in 15242 ms
With response headers:
    
2025-05-12T20:08:23.938Z: Failed to perform the initial theme synchronization.
FetchError: request to https://voice-of-defiance.myshopify.com/admin/api/2025-04/graphql.json failed, reason: socket hang up
    at ClientRequest.<anonymous> (file:///home/xxx/.nvm/versions/node/v21.5.0/lib/node_modules/@shopify/cli/dist/chunk-JED5Q5EJ.js:17594:18)
    at ClientRequest.emit (node:events:519:28)
    at ClientRequest.emit (node:domain:488:12)
    at TLSSocket.socketOnEnd (node:_http_client:519:9)
    at TLSSocket.emit (node:events:531:35)
    at TLSSocket.emit (node:domain:488:12)
    at endReadableNT (node:internal/streams/readable:1696:12)
    at process.processTicksAndRejections (node:internal/process/task_queues:82:21)

Could you please have a look? It seems it’s still failing after 15s.

I am having the same issue on my mac having had to replace my hard drive and update to the latest OS. I have spent 5 hours trying to install different many versions but to no avail. I think I used to have v2 before but can’t seem to install that anymore, so gonna have to keep trying with v3x.

UPDATE: Having tried many different versions, got this one to work: 3.70.0 npm install -g /cli@3.70.0

Thanks to this thread: https://community.shopify.com/c/shopify-discussions/can-run-shopify-theme-dev-on-the-latest-version-of-shopify-cli-3/m-p/2868197#M484569

If anyone is still getting errors, I would love to grab the request ID so that I can do more digging.

I am getting this issue. I do not always get a request ID.

First time I ran shopify app dev it ran fine and then closed. Second time I had to auth again and then it hung up after login. Then I got a 500 response. Now I just get “The user aborted a request”

Request ID: 245b1c66-f016-40f1-bb0b-35558ab9dd83-1749164772 Request ID: 1c850f15-bf1e-450a-98cc-44f2ff88b9e7-1749164732

These are the only two times I have gotten a request id back. More times I get “The user aborted a request”

It was working fine a few days ago, nothing changed code wise but now this is a problem today.

@annaweaver @jackwuzz I confirm, downgrade to 3.70.0 will solve this issue

@djordje-st how did you add the flag into the cli command please, going through the same issue and have tried to use a “shopify.theme.toml” for theme dev. cannot find the flags to use for this. thank you