-
Notifications
You must be signed in to change notification settings - Fork 450
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
Presentation in infinite "Loading" state (http local, https remote) #8748
Comments
Hi @ChrisNolan,
hook.js:608 Unable to connect to visual editing. Make sure you've setup '@sanity/visual-editing' correctly Could you share your For that mismatch to happen the iframe must be redirected somehow? |
Hi @stipsan I think I have a fairly straight forward setup presentation tool wise...
Do you want my full resolve as well?
My SANITY_STUDIO_PREVIEW_ORIGIN is simply I can't think of how it would be doing any redirecting... the site at that preview_origin is just a nextjs app with normal routing as far as I know (does it do any hidden redirects?). I just tried going straight to the presentation tab rather than clicking through via a 'resolve' link and see this in the log instead but the infinite spinner still. If it matters I used this options when doing the deploy: |
Thanks, this is super helpful! In any case I think the solution for you is to run |
Thanks for the reminder about --experimental-https ; I think I had tried it and it only worked connecting to localhost and not 0.0.0.0 so getting it 'out' of the container it was in wasn't working. But it was a busy time getting that deployed the first time and I'll take another look. I was also told there is a 'registry edit' to allow the browser to go to an http from an https but was told it shouldn't be done 'just in case' there was somebody nefarious out there. |
If you find a security vulnerability, do NOT open an issue. Email [email protected] instead.
Describe the bug
If you have a deployed studio which is configured to use a local server as the host, but the local server is 'http' and not 'https' the presentation tool gets 'stuck' infinitely 'loading' without any message about what the problem is.
The console files with
To Reproduce
Steps to reproduce the behavior:
Expected behavior
Some notice about what is wrong with the configuration rather than infinitely "Loading".
Screenshots

Which versions of Sanity are you using?
@sanity/cli (global) 3.74.1 (latest: 3.77.0)
@sanity/code-input 5.1.2 (up to date)
@sanity/dashboard 4.1.2 (up to date)
@sanity/eslint-config-studio 4.0.0 (latest: 5.0.1)
@sanity/image-url 1.1.0 (up to date)
@sanity/preview-url-secret 2.1.4 (up to date)
@sanity/vision 3.74.1 (latest: 3.77.0)
sanity 3.74.1 (latest: 3.77.0)
What operating system are you using?
ubuntu?
Which versions of Node.js / npm are you running?
Run
npm -v && node -v
in the terminal and copy-paste the result here.9.8 something and 22. something behind an nginx thingy. Technical, eh?
Additional context
Add any other context about the problem here.
Security issue?
Any security issues should be submitted directly to [email protected]. In order to determine whether you are dealing with a security issue, ask yourself these two questions:
The text was updated successfully, but these errors were encountered: