-
Notifications
You must be signed in to change notification settings - Fork 200
[Bug]: NoMethodError: undefined method `shop' for nil:NilClass #2059
Comments
Same problem |
Looking into this... for the record the error message you're probably supposed to see is:
|
I can confirm I have full access to edit the store and theme. |
If you're the store owner, then you need to log in to the store directly using the store URL at least once (for example, using {shop}.myshopify.com/admin) before you log in using Shopify CLI. Logging in to the Shopify admin directly connects the development store with your Shopify login.
|
- potentially addresses Shopify#2059, where user is logged in but they have no theme edit permissions (or otherwise aren't correctly authenticated) - after updates in Shopify#2020, there is no theme object if there is a permissions error so we need to create a new generic one to get access to the shop name for the error message - additionally I noticed that the other theme commands in this same case were raising 403 errors rather than showing a correct error message
Same issue. I'm the store owner and have logged into the CMS of the store.
|
Creating a staff member with a different email address solved it for me. |
I have the same problem, but I create a staff member with a different email address as above, however this is a workaround, it's not solved! |
What worked for me was:
For some reason I had to repeat all the steps above couple of times |
What worked for me:
|
For my case, I had to downgrade gem uninstall shopify-cli
gem install shopify-cli -v 2.7.4 |
Resolved by #2114. |
(If this issue gets re-opened, I will re-assign it to me @kilgore5. But, for now, it seems like you've solved it! 🎉) |
Nope still broken, not resolved |
Thanks for reporting it, @BryanCastro. Could you please share the stack trace you're facing and the Shopify CLI version? |
worked for me, I tried to run "shopify login" without logging out my other shopify account |
Hi, in my case specifying the exact store I'm trying to login helped: For example, if you have already logged into your account and it is not working you can try this:
|
Please confirm that you have:
What type of project are you working on?
theme
Expected behavior
Expecting
shopify theme serve
to server the current theme.Actual behavior
Stack trace
Reproduction steps
After install shopify-cli I ran:
Operating System
universal.x86_64-darwin21
CLI version (run
shopify version
if you're not sure)2.11.2
Shell
/bin/zsh
Ruby version (run
ruby -v
if you're not sure)2.6.8p205
What language and version are you using in your application?
No response
The text was updated successfully, but these errors were encountered: