Closed bansavage closed 6 months ago
Also running into this.
As an update, I have tried numerous troubleshooting steps:
brew tap shopify/shopify && brew install shopify-cli
. Issue remainsnpm install -g @shopify/cli @shopify/theme
and issue remainsThe error remains the same:
Error coming from `bundle install`
Command failed with exit code 5: bundle install
Gem::Ext::BuildError: ERROR: Failed to build gem native extension.
current directory:
/Users/bansavage/Library/Caches/shopify-gems-nodejs/ruby/3.3.0/gems/nokogiri-1.14.5/ext/nokogiri
/opt/homebrew/opt/ruby/bin/ruby extconf.rb
The only temporary fix is to run export SHOPIFY_CLI_BUNDLED_THEME_CLI=1
though it seems very unstable
Seems like the gem "nokogiri-1.14.5" is blowing up..unsure of how to proceed.
Same issue here
I just upgraded to 3.58.2 and when running Shopify theme dev, it does nothing
Yes @jcdatu1, mine "does nothing" as well then vomits out the error shown above. Ever since the upgrade. I really wish we could get some support here...
Confirming the newest version fixed this, should someone stumble upon this
@bansavage me too :)
I’m still seeing this on 3.59.0.
Update: It stopped happening, not sure why. 3.59.0 works here, too.
I get the error on @shopify/cli@3.58.0.
It is working on @shopify/cli@3.59.0
Still got the issue, on my Macbook pro M2 using ARM.
shopify --version
@shopify/cli/3.59.0 darwin-arm64 node-v20.15.0
$ shopify theme dev --store=...
── external error ────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
Error coming from `bundle install`
Command failed with exit code 1: bundle install
zsh:1: command not found: chruby
--- ERROR REPORT TEMPLATE -------------------------------------------------------
LoadError: cannot load such file -- zlib
<internal:/Users/dzheng/.rvm/rubies/ruby-3.3.1/lib/ruby/3.3.0/rubygems/core_ext/kernel_require.rb>:136:in `require'
<internal:/Users/dzheng/.rvm/rubies/ruby-3.3.1/lib/ruby/3.3.0/rubygems/core_ext/kernel_require.rb>:136:in `require'
/Users/dzheng/.rvm/rubies/ruby-3.3.1/lib/ruby/3.3.0/bundler/fetcher.rb:7:in `<top (required)>'
<internal:/Users/dzheng/.rvm/rubies/ruby-3.3.1/lib/ruby/3.3.0/rubygems/core_ext/kernel_require.rb>:136:in `require'
<internal:/Users/dzheng/.rvm/rubies/ruby-3.3.1/lib/ruby/3.3.0/rubygems/core_ext/kernel_require.rb>:136:in `require'
/Users/dzheng/.rvm/rubies/ruby-3.3.1/lib/ruby/3.3.0/bundler/cli/install.rb:50:in `run'
/Users/dzheng/.rvm/rubies/ruby-3.3.1/lib/ruby/3.3.0/bundler/cli.rb:244:in `block in install'
/Users/dzheng/.rvm/rubies/ruby-3.3.1/lib/ruby/3.3.0/bundler/settings.rb:158:in `temporary'
/Users/dzheng/.rvm/rubies/ruby-3.3.1/lib/ruby/3.3.0/bundler/cli.rb:243:in `install'
/Users/dzheng/.rvm/rubies/ruby-3.3.1/lib/ruby/3.3.0/bundler/vendor/thor/lib/thor/command.rb:28:in `run'
/Users/dzheng/.rvm/rubies/ruby-3.3.1/lib/ruby/3.3.0/bundler/vendor/thor/lib/thor/invocation.rb:127:in `invoke_command'
/Users/dzheng/.rvm/rubies/ruby-3.3.1/lib/ruby/3.3.0/bundler/vendor/thor/lib/thor.rb:527:in `dispatch'
/Users/dzheng/.rvm/rubies/ruby-3.3.1/lib/ruby/3.3.0/bundler/cli.rb:34:in `dispatch'
/Users/dzheng/.rvm/rubies/ruby-3.3.1/lib/ruby/3.3.0/bundler/vendor/thor/lib/thor/base.rb:584:in `start'
/Users/dzheng/.rvm/rubies/ruby-3.3.1/lib/ruby/3.3.0/bundler/cli.rb:28:in `start'
/Users/dzheng/.rvm/rubies/ruby-3.3.1/lib/ruby/gems/3.3.0/gems/bundler-2.5.9/exe/bundle:28:in `block in <top (required)>'
/Users/dzheng/.rvm/rubies/ruby-3.3.1/lib/ruby/3.3.0/bundler/friendly_errors.rb:117:in `with_friendly_errors'
/Users/dzheng/.rvm/rubies/ruby-3.3.1/lib/ruby/gems/3.3.0/gems/bundler-2.5.9/exe/bundle:20:in `<top (required)>'
/Users/dzheng/.rvm/rubies/ruby-3.3.1/bin/bundle:25:in `load'
/Users/dzheng/.rvm/rubies/ruby-3.3.1/bin/bundle:25:in `<main>'
Bundler 2.5.9
Platforms ruby, arm64-darwin-23
Ruby 3.3.1p55 (2024-04-23 revision c56cd86388092faec079981f779f140717020d58) [arm64-darwin-23]
Full Path /Users/dzheng/.rvm/rubies/ruby-3.3.1/bin/ruby
Config Dir /Users/dzheng/.rvm/rubies/ruby-3.3.1/etc
RubyGems 3.5.9
Gem Home /Users/dzheng/.rvm/gems/ruby-3.3.1
Gem Path /Users/dzheng/.rvm/gems/ruby-3.3.1:/Users/dzheng/.rvm/rubies/ruby-3.3.1/lib/ruby/gems/3.3.0
User Home /Users/dzheng
User Path /Users/dzheng/.gem/ruby/3.3.0
Bin Dir /Users/dzheng/.rvm/gems/ruby-3.3.1/bin
Tools
Git 2.45.2
RVM 1.29.12 (latest)
rbenv rbenv 1.2.0
chruby
Built At 2024-07-30
Git SHA unknown
Released Version false
## Bundler settings
path
Set via BUNDLE_PATH: "/Users/dzheng/Library/Caches/shopify-gems-nodejs"
without
Set via BUNDLE_WITHOUT: [:development, :test]
## Gemfile
### Gemfile
# NOTE: These are development-only dependencies
source "https://rubygems.org"
gem "bugsnag", "~> 6.22"
gem "listen", "~> 3.7.0"
# None of these can actually be used in a development copy of dev
# They are all for CI and tests
# `dev` uses no gems
group :development, :test do
gem "pry-byebug"
gem "byebug"
gem "rubocop-shopify", require: false
gem "rubocop-minitest", require: false
gem "rubocop-rake", require: false
gem "iniparse", "~> 1.5"
gem "colorize", "~> 0.8.1"
gem "bundler", ">= 2.3.11"
gem "rake", "~> 12.3", ">= 12.3.3"
gem "minitest", "~> 5.0"
end
group :test do
gem "mocha", require: false
gem "minitest-reporters", require: false
gem "minitest-fail-fast", require: false
gem "fakefs", ">= 1.0", require: false
gem "webmock", require: false
gem "timecop", require: false
gem "rack", require: false
gem "cucumber", "~> 7.0", require: false
end
### Gemfile.lock
<No /Users/dzheng/.nvm/versions/node/v18.17.1/lib/node_modules/@shopify/cli/dist/assets/cli-ruby/Gemfile.lock found>
--- TEMPLATE END ----------------------------------------------------------------
Unfortunately, an unexpected error occurred, and Bundler cannot continue.
First, try this link to see if there are any existing issue reports for this error:
https://github.com/rubygems/rubygems/search?q=cannot+load+such+file+--+zlib&type=Issues
If there aren't any reports for this error yet, please fill in the new issue form located at https://github.com/rubygems/rubygems/issues/new?labels=Bundler&template=bundler-related-issue.md, and copy and paste the report template above in
there.
──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
Please confirm that you have:
In which of these areas are you experiencing a problem?
Theme
Expected behavior
shopify theme dev
should work as expected and start the local server. I updated my CLI to the latest version using homebrew commandsbrew upgrade && brew update
. Following thisshopify theme dev
errors out.Actual behavior
shopify theme dev
errors out after upgrading to latest version. The only fix is to runSHOPIFY_CLI_BUNDLED_THEME_CLI=1 shopify theme dev
The errors is related to Ruby bundling, and the error log states:
Verbose output
Reproduction steps
arch -arm64 brew tap shopify/shopify
arch -arm64 brew install shopify-cli
shopify theme dev
and/orarch -arm64 shopify theme dev
Operating System
M1 Macbook - MacOS Sonoma 14.4.1 (23E224)
Shopify CLI version (check your project's
package.json
if you're not sure)@shopify/cli/3.58.2 darwin-arm64 node-v21.7.2
Shell
zsh
Node version (run
node -v
if you're not sure)v21.7.2
What language and version are you using in your application?
Ruby v3.3.0, Node v21.7.2, ALL INSTALLED BY Homebrew shopify-cli install