npm run dev results in error: Cannot read properties of undefined (reading 'output')

npm run dev results in error: Cannot read properties of undefined (reading 'output')

Mat_Brummitt
Shopify Partner
52 1 15

Hi,

 

I've been working on an app for over a year and i'm now ready to deploy. I read the Shopify docs relating to deployments, and I found that Shopify now recommends installing the CLI globally, whereas it used to recommend a local install per project. I didn't want to risk anything breaking, so I've left the CLI a local install to the project, but I did go ahead and upgrade the CLI a number of minor versions becuase mine had gone a little out of date.

 

Since updating my package.json file to use the latest CLI version, and running npm install, my app now generates an error when running npm run dev where the following error appears in the terminal:

 

Cannot read properties of undefined (reading 'output')

To investigate the issue, examine this stack trace:

...

 

I reverted back to my original version which has been working for me over the last 9 months+ and now I still get this error.

 

The stack trace includes a whole bunch of chunk files which mean nothing to me when I look at them.  Here's the stack trace output with the above error, in case it helps. I've redacted any file paths as I assume it's only text in yellow that's going to be helpful to anyone reading this:

Mat_Brummitt_1-1726671591390.png

I'm very frustrated with this, so really hoping someone is able to offer advice. After a long development period I'm keen to be able to finally launch this application, so I really appreciated any help anyone can give.

 

Note: In the past i've had issues that randomly come up with no change to my own code, only for it to be related to CloudFlare Tunnel issues. Might that be at play here, and it's just coincidiental that this issue occurs right as I was going to update the CLI?

 

Thanks

 

Mat

Replies 7 (7)

Namito93
Shopify Partner
4 0 4

Same here, the error preventing me to run app dev: 

Namito93_0-1726684376035.png

 

Mat_Brummitt
Shopify Partner
52 1 15

If you're getting the same issue, I assume then that this is not related to me having upgraded the CLI since I downgraded it and still got the issue. How long have you been experiencing the issue, and did it come out of nowhere or did you do something to your project which might have triggered this?

 

Thanks

 

Mat

Namito93
Shopify Partner
4 0 4

No more errors with v3.66.0 >>>>>>>>>>  npm install -g @Shopify/cli@3.66.0

jimbeam4
Shopify Partner
1 0 0

I am experiencing the same issue w/ v3.67.0, that was installed via homebrew on MacOS Sequoia 15.0

Magecomp-User
Shopify Partner
5 0 1

I have same issue

MagecompUser_0-1726817925368.png

 

tim-permutable
Shopify Partner
8 0 0

Got exactly the same issue when updating CLI yesterday.

ismail_zafar
Shopify Partner
1 0 0

I am also getting same error after cli upgrade.