Key context: Shopify CLI manages theme development; theme serve runs a local dev server; theme pull fetches a store theme.
Reported fixes/workarounds:
Session reset: Log out of Shopify in the browser and CLI (shopify logout), log into the store admin in the browser, then shopify login --store {shop}.myshopify.com. This enabled theme serve for some. OP succeeded after repeating steps with a different partner account.
Explicit theme selection: After shopify theme list, run shopify theme pull {theme-name} and confirm selection when prompted. One user also changed runtimes (Ruby 3.0.0, Node >14); pull worked, but theme serve still had issues.
Correct working directory: Error resolved when files were moved to the proper theme directory.
Other note: A user reported shopify login not found (CLI suggested hydrogen login), indicating possible CLI version/command differences.
Status: No single root cause. Multiple workarounds helped; some theme serve issues remain for certain setups.
Summarized with AI on December 20.
AI used: gpt-5.
I installed the latest versions of Ruby, Git, and Shopify CLI but when I use the command “Shopify theme serve” I got this error and also same for the command “Shopify theme pull”.
"X An unexpected error occurred.
To submit an issue include the stack trace.
? Send an anonymized error report to Shopify? (Navigate up with ‘k’ and down with ‘j’, press Enter to select, filter with
‘f’)
Yes, send
No, don’t send"
And I already added SHOPIFY_CLI_STACKTRACE=1 in the environmental variables.
I tried different solutions to solve this error but am not able to solve it so please kindly help me with this.
I tried your solution again with a different partner account and it worked for me.
Thanks a lot! i almost wasted 2 days to solve this issue.
Thanks again! really appreciate your help!
I stumbled on this issue today and spent hours and hours to track it down and get solved.
Initially, I downgraded my ruby version to 3.0.0 and upgraded node to above 14 version.
The problem persisted and I ran the command
shopify theme pull shopify-mystore
adding the theme name after the command just as it appears when I ran
shopify theme list
Finally it went through but not before displaying me the list of themes on my store and asking me to confirm by the number of it. This time the pull went through and I found myself in another problem on the