Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug]: You cannot use gems with Shopify CLI - shopify theme pull - Shopify cli 3.53 #3221

Closed
2 tasks done
alemNative opened this issue Jan 3, 2024 · 11 comments
Closed
2 tasks done
Labels
Type: Bug Something isn't working

Comments

@alemNative
Copy link

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

hey guys since last weeks some updates breaks my shopify cli.
When i try to make some shopify theme commands i get this output:

`[Note] You cannot use gems with Shopify CLI.
[LoadError] cannot load such file -- json
They are disabled.
Please don't modify the CLI locally.
If you would like to contribute to the CLI project, please refer to
https://github.com/Shopify/shopify-cli/blob/main/.github/CONTRIBUTING.md

[Note] You cannot use gems with Shopify CLI.
[LoadError] cannot load such file -- json
They are disabled.
Please don't modify the CLI locally.
If you would like to contribute to the CLI project, please refer to
https://github.com/Shopify/shopify-cli/blob/main/.github/CONTRIBUTING.md

[Note] You cannot use gems with Shopify CLI.
[LoadError] cannot load such file -- json
They are disabled.
Please don't modify the CLI locally.
If you would like to contribute to the CLI project, please refer to
https://github.com/Shopify/shopify-cli/blob/main/.github/CONTRIBUTING.md

internal:/usr/lib/ruby/site_ruby/3.0.0/rubygems/core_ext/kernel_require.rb:37:in require': cannot load such file -- json (LoadError) from <internal:/usr/lib/ruby/site_ruby/3.0.0/rubygems/core_ext/kernel_require.rb>:37:in require'
from /usr/lib/node_modules/@shopify/theme/node_modules/@shopify/cli-kit/assets/cli-ruby/bin/shopify:9:in require' from /usr/lib/node_modules/@shopify/theme/node_modules/@shopify/cli-kit/assets/cli-ruby/lib/shopify_cli/context.rb:6:in <top (required)>'
from internal:/usr/lib/ruby/site_ruby/3.0.0/rubygems/core_ext/kernel_require.rb:37:in require' from <internal:/usr/lib/ruby/site_ruby/3.0.0/rubygems/core_ext/kernel_require.rb>:37:in require'
from /usr/lib/node_modules/@shopify/theme/node_modules/@shopify/cli-kit/assets/cli-ruby/bin/shopify:9:in require' from /usr/lib/node_modules/@shopify/theme/node_modules/@shopify/cli-kit/assets/cli-ruby/lib/shopify_cli.rb:133:in module:ShopifyCLI'
from /usr/lib/node_modules/@shopify/theme/node_modules/@shopify/cli-kit/assets/cli-ruby/lib/shopify_cli.rb:42:in <top (required)>' from <internal:/usr/lib/ruby/site_ruby/3.0.0/rubygems/core_ext/kernel_require.rb>:37:in require'
from internal:/usr/lib/ruby/site_ruby/3.0.0/rubygems/core_ext/kernel_require.rb:37:in require' from /usr/lib/node_modules/@shopify/theme/node_modules/@shopify/cli-kit/assets/cli-ruby/bin/shopify:9:in require'
from /usr/lib/node_modules/@shopify/theme/node_modules/@shopify/cli-kit/assets/cli-ruby/bin/load_shopify.rb:18:in <top (required)>' from /usr/lib/node_modules/@shopify/theme/node_modules/@shopify/cli-kit/assets/cli-ruby/bin/shopify:45:in require_relative'
from /usr/lib/node_modules/@shopify/theme/node_modules/@shopify/cli-kit/assets/cli-ruby/bin/shopify:45:in <main>'
try to install with gems json, wdm, bundler dosent helps

my shopify theme info is:
`THEME CONFIGURATION
Store domain.myshopify.com
Development Theme ID Not set

TOOLING AND SYSTEM
Shopify CLI 3.53.0
OS linux-amd64
Shell /usr/bin/zsh
Node version v21.5.0
Ruby version 3.0.6
`
also reinstalling npm, nodejs and the shopify cli dosent helps.

Actual behavior

`[Note] You cannot use gems with Shopify CLI.
[LoadError] cannot load such file -- json
They are disabled.
Please don't modify the CLI locally.
If you would like to contribute to the CLI project, please refer to
https://github.com/Shopify/shopify-cli/blob/main/.github/CONTRIBUTING.md

[Note] You cannot use gems with Shopify CLI.
[LoadError] cannot load such file -- json
They are disabled.
Please don't modify the CLI locally.
If you would like to contribute to the CLI project, please refer to
https://github.com/Shopify/shopify-cli/blob/main/.github/CONTRIBUTING.md

[Note] You cannot use gems with Shopify CLI.
[LoadError] cannot load such file -- json
They are disabled.
Please don't modify the CLI locally.
If you would like to contribute to the CLI project, please refer to
https://github.com/Shopify/shopify-cli/blob/main/.github/CONTRIBUTING.md

internal:/usr/lib/ruby/site_ruby/3.0.0/rubygems/core_ext/kernel_require.rb:37:in require': cannot load such file -- json (LoadError) from <internal:/usr/lib/ruby/site_ruby/3.0.0/rubygems/core_ext/kernel_require.rb>:37:in require'
from /usr/lib/node_modules/@shopify/theme/node_modules/@shopify/cli-kit/assets/cli-ruby/bin/shopify:9:in require' from /usr/lib/node_modules/@shopify/theme/node_modules/@shopify/cli-kit/assets/cli-ruby/lib/shopify_cli/context.rb:6:in <top (required)>'
from internal:/usr/lib/ruby/site_ruby/3.0.0/rubygems/core_ext/kernel_require.rb:37:in require' from <internal:/usr/lib/ruby/site_ruby/3.0.0/rubygems/core_ext/kernel_require.rb>:37:in require'
from /usr/lib/node_modules/@shopify/theme/node_modules/@shopify/cli-kit/assets/cli-ruby/bin/shopify:9:in require' from /usr/lib/node_modules/@shopify/theme/node_modules/@shopify/cli-kit/assets/cli-ruby/lib/shopify_cli.rb:133:in module:ShopifyCLI'
from /usr/lib/node_modules/@shopify/theme/node_modules/@shopify/cli-kit/assets/cli-ruby/lib/shopify_cli.rb:42:in <top (required)>' from <internal:/usr/lib/ruby/site_ruby/3.0.0/rubygems/core_ext/kernel_require.rb>:37:in require'
from internal:/usr/lib/ruby/site_ruby/3.0.0/rubygems/core_ext/kernel_require.rb:37:in require' from /usr/lib/node_modules/@shopify/theme/node_modules/@shopify/cli-kit/assets/cli-ruby/bin/shopify:9:in require'
from /usr/lib/node_modules/@shopify/theme/node_modules/@shopify/cli-kit/assets/cli-ruby/bin/load_shopify.rb:18:in <top (required)>' from /usr/lib/node_modules/@shopify/theme/node_modules/@shopify/cli-kit/assets/cli-ruby/bin/shopify:45:in require_relative'
from /usr/lib/node_modules/@shopify/theme/node_modules/@shopify/cli-kit/assets/cli-ruby/bin/shopify:45:in `

Verbose output

no

Reproduction steps

  1. just try on linux to run shopify theme pull and so on

Operating System

Linux

Shopify CLI version (check your project's package.json if you're not sure)

3.53

Shell

No response

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

No response

What language and version are you using in your application?

No response

@alemNative alemNative added the Type: Bug Something isn't working label Jan 3, 2024
@mkbodanu4
Copy link

Got a similar error while working with the theme app extension.
Found that updated packages in my Arch Linux installation a few days ago, including ruby-json package.
Downgraded ruby-json package from 2.7.1-1 to 2.6.3-1 and got everything working.

@alemNative
Copy link
Author

alemNative commented Jan 3, 2024

i try to downgrade with yay -S ruby-json=2.6.3-1 but it dosent work. maybe because of an dependency. should cli not work with the new version?

what ever i do it installs at the end 2.7.1-1

@alemNative
Copy link
Author

i downgrade it now with the downgrade package. and it works now. hope cli will be soon updated. i can work for now... but doesen´t looks like a final solution.

@networkmushokto
Copy link

i downgrade it now with the downgrade package. and it works now. hope cli will be soon updated. i can work for now... but doesen´t looks like a final solution.

@alemNative hello can you tell me what version are you using?

I getting same error.

@alemNative
Copy link
Author

Same like mkbodanu4. i downgrade ruby-json on archlinux to 2.6.3-1. then it works.

@networkmushokto
Copy link

Same like mkbodanu4. i downgrade ruby-json on archlinux to 2.6.3-1. then it works.

hello thanks for fast response,

I also use archlinux but I keep failing to install ruby 2.6.3-1 via rvm. can you show me step to downgrade it?

@alemNative
Copy link
Author

yes its anoying. there is a arch package who's name downgrade or something like that. With this you can hold any package down...
check it: https://github.com/archlinux-downgrade/downgrade

@r0skar
Copy link

r0skar commented Jan 22, 2024

Came here to add that I experience the same issue with 2.7.1-1, but works with 2.6.3-1.

@cypherpower
Copy link

Also on arch had the same error and had to revert ruby-json package

@shtanaka
Copy link

Also on arch, downgraded ruby-json using downgrade arch package.

DOWNGRADE_FROM_ALA=1 downgrade 'ruby-json=2.6.3-1'

@A
Copy link

A commented Jun 10, 2024

On arch. Enjoyed running makepgk -si. Thank you guys a lot, you saved a lot of lovely debugging time to me!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Type: Bug Something isn't working
Projects
None yet
Development

No branches or pull requests

7 participants