'shopify theme dev' fails installing theme dependencies

'shopify theme dev' fails installing theme dependencies

claralayti
Shopify Partner
1 0 1

I followed the Shopify CLI guideline for themes, as usual, and got stuck after the 'shopify theme dev'. It should upload the current theme to a store so I can preview it, but, instead I get this error (here's a snippet).

 

/opt/homebrew/Cellar/shopify-cli/3.43.0/libexec/lib/node_modules/@shopify/cli/node_modules/yoga-layout-prebuilt/yoga-layout/build/Release/nbind.js:53
        throw ex;
        ^

ExternalError: Command failed with exit code 5: /opt/homebrew/opt/ruby/bin/bundle install
Gem::Ext::BuildError: ERROR: Failed to build gem native extension.

 

I am working on Mac OS Venutra,  with Shopify 3.43.0 and node.js v19.6.0

 

Someone knows what is going on? This has happened all of a sudden

Replies 9 (9)

EcomGraduates
Shopify Partner
757 66 110

hello there 

 

The error message suggests that there is an issue with building the native extension for a gem, which may be causing the bundle install command to fail. Here are some troubleshooting steps you can try:

  1. Check if all the required dependencies for building the native extensions are installed on your system. Depending on the gem, you may need to have certain tools or libraries installed. You can check the gem's documentation or the error message for more information.

  2. Try running bundle install directly in your theme directory to see if it produces a more informative error message.

  3. If the problem persists, you can try deleting the Gemfile.lock file in your theme directory and running bundle install again. This will force the bundler to rebuild the dependencies from scratch.

  4. You can also try updating your Ruby installation and installing the bundler gem, as the issue may be related to the version of Ruby or bundler.

 


 If this fixed your issue, likes and accepting as a solution are highly appreciated
|  Build an online presence with our custom-built Shopify Theme: EcomifyTheme
|  Check out our reviews: Trustpilot Reviews
|  We are Shopify Partners: EcomGraduates Shopify Partner



md-abdullah
Shopify Partner
3 0 3

Hello, when I run `bundle install`, give an error-`Could not locate Gemfile`.

Abdullah
Get Quick Response via Email
MarceloDias
Shopify Partner
3 0 0

I have the same error, did you find the solution?

Muscled
Shopify Partner
3 0 1

I'm also getting same error

did you find any solution? 

Muscled_1-1691271826999.png

 

Muscled
Shopify Partner
3 0 1

I'm also getting this same error

Muscled_0-1691271724887.png

bytescoop
Shopify Partner
5 0 3

Hello @claralayti 

Did you find any solution for this? I am getting this same error. 

Please help me if you find any solution. 

 

Thank you!

Muscled
Shopify Partner
3 0 1

If you have found any solution, can you please share with me

Thank You

Muscled_2-1691271911715.pngMuscled_3-1691271955649.png

 

Ole_
Shopify Partner
43 8 20

For me, this did the trick...

 

Open Terminal and run

xcode-select --install

 
A popup dialogue box will open (Might be hidden behind other windows). Click "Install" and install the Command Line Tool Package.

 

If this doesn't work, also run

sudo xcode-select --reset

 

(You don't need to have Xcode installed to do all that)

If you find my suggestions helpful, kindly express your feedback by liking or marking them as a solution.
Our (German) agency: visionz.de
Our Shopify App for custom pricing & unlimited product options: Visionz Easy Product Options

MobileEscape
Tourist
4 1 3

you need to have Ruby installed. Go to the terminal and run 

brew install ruby

after that run 

brew tap shopify/shopify
brew install shopify-cli

to update to the latest cli.
If you are running into permission issues, run:

sudo chown -R <your-user-name> /opt/homebrew /opt/homebrew/share/zsh /opt/homebrew/share/zsh/site-functions /opt/homebrew/var/homebrew/locks

replace <your-user-name> with your current OS user name